File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed
repository/Grease-Core.package/GRPlatform.class/instance Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change 1+ file library
2+ asMethodReturningString: aByteArrayOrString named: aSymbol
3+ " Generates the source of a method named aSymbol that returns aByteArrayOrString as a String.
4+
5+ This implementation answers a String formatted like so
6+
7+ aSymbol
8+ ^ aByteArrayOrString
9+
10+ Subclasses need to override this method if the dialect needs changes to support Unicode string literals"
11+ ^ String streamContents: [ :stream |
12+ stream
13+ nextPutAll: aSymbol;
14+ nextPut: Character cr.
15+ stream
16+ tab;
17+ nextPutAll: ' ^ ' ' ' .
18+ aByteArrayOrString greaseString do: [ :each |
19+ each = $' ifTrue: [ stream nextPut: $' ].
20+ stream nextPut: each ].
21+ stream nextPut: $' ]
You can’t perform that action at this time.
0 commit comments