Comments (13)
It looks better!
from guider.
I propose to reconsider and improve also special string concatenations which can be found with the help of a search pattern like the following.
[Markus_Elfring@fedora guider]$ grep --perl-regexp --count "(\w+)\s*=\s*('|\")%s.*%s.*\2\s*%\s*\(\1,.+\)" guider.py
113
Example:
if SysMgr.lineLength > nowLen + len(nextCall):
- userCall = '%s%s' % (userCall, nextCall)
+ userCall += nextCall
nowLen += len(nextCall)
Would you like to adjust any more questionable data processing details?
from guider.
I agree with you!
I'll fix them!
from guider.
Would you like to use any development tools which can help a bit more to perform mass source code transformations?
from guider.
Yes, I would like to use those tools if I can use them.
Could you recommend any tools?
from guider.
- Something can be achieved by the application of advanced regular expressions to some degree.
- Do you know any development tools which can take regex captures better into account?
- How do you think about to extend possibilities for collateral evolution by means of variations with computation tree logic?
from guider.
Thanks for another source code improvement.
I guess that there are more remaining update candidates to consider according to the discussed transformation pattern.
Additional change suggestion:
else:
- userCall = '%s\n%s %s' % \
- (userCall, ' ' * indentLen, nextCall)
+ userCall += '\n%s %s' % (' ' * indentLen, nextCall)
nowLen = indentLen + len(nextCall)
Would you find development tools (like the following) helpful?
from guider.
Yes, I would like to use those tools if I can use them.
Would you like to integrate anything from a source code transformation result which can be generated by a command like the following?
(
[Markus_Elfring@fedora lokal]$ ./comby -diff ':[[a]] = :[a] + :[[b]]' ':[a] += :[b]' $(find /home/altes_Heim2/elfring/Projekte/guider/lokal -name '*.py')
from guider.
I checked this result :)
some lines are wrong but other is useful :)
+++ guider.py
@@ -20727,12 +20727,12 @@
data2 = ord(source[count])
thisVal = data1*256 + data2
- sum = sum + thisVal
+ sum += thisVal
sum = sum & 0xffffffff # Necessary?
- count = count + 2
+ count += 2
if countTo < len(source):
- sum = sum + ord(source[len(source) - 1])
+ sum += ord(source[len(source) - 1])
sum = sum & 0xffffffff # Necessary?
sum = (sum >> 16) + (sum & 0xffff)
@@ -62803,7 +62803,7 @@
if sym.endswith(Debugger.RETSTR):
rsym = sym
else:
- rsym = sym + Debugger.RETSTR
+ rsym += Debugger.RETSTR
# add return stats #
if rsym in instance.callTable and \
@@ -67605,7 +67605,7 @@
struct.unpack('HHHHIII', target)
# get verdef strings #
- soffset = offset + vd_aux
+ soffset += vd_aux
for vidx in range(vd_cnt):
starget = verdef_section[soffset:soffset+sentsize]
vda_name, vda_next = \
@@ -67643,7 +67643,7 @@
struct.unpack('HHIII', target)
# get verneed strings #
- soffset = offset + entsize
+ soffset += entsize
for vidx in range(vn_cnt):
starget = verneed_section[soffset:soffset+entsize]
vna_hash, vna_flags, vna_other, vna_name, vna_next = \
from guider.
some lines are wrong but other is useful
(
[Markus_Elfring@fedora lokal]$ perl -p -i.orig -0777 -e 's/^(?<indentation>\s+)(?<target>\S+)\s*=\s*\k<target>\s*(?<operator>[+\-%&|^@]|\*\*?|\/\/?|<<|>>)/$+{indentation}$+{target} $+{operator}=/gm' $(find /home/altes_Heim2/elfring/Projekte/guider/lokal -name '*.py')
from guider.
How do you think about to share insights for the evolution of run time characteristics (eventually also for a software component like βSly Lex Yaccβ) together with adjustments for discussed implementation details?
from guider.
from guider.
I also like the augmented assignment expression :)
I already applied it in manual and using your scripts.
from guider.
Related Issues (20)
- Subsecond cpu top feature HOT 1
- Checking status for data recording HOT 17
- Fix exception handling for the import of essential modules HOT 3
- Split the grown script into loadable modules HOT 6
- Fix specifications of exit codes for the Guider launcher HOT 1
- Choose an error code according to a wrong depth type HOT 1
- Choose an error code according to a failed priority setting HOT 1
- Addition of a build system generator HOT 4
- Improve build support for newer Python versions HOT 1
- Fix error indication for a successful program analysis HOT 7
- Export tracing data in tabular form HOT 8
- Export tracing records in rows instead of multi-line structures HOT 49
- Increase selection of data output streams HOT 6
- Provide numerical data instead of texts in output streams HOT 2
- Support the configuration of a shell environment before tracing a passed command HOT 10
- Reconsider βimport gcβ HOT 1
- Checking repetition for dictionary entry βstatxβ HOT 2
- Is it possible to record the process usage based on process id HOT 5
- release? HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from guider.