scad 0.1 → 0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rspec +1 -0
- data/Gemfile +58 -0
- data/Gemfile.lock +34 -0
- data/README.md +52 -10
- data/Rakefile +47 -0
- data/examples/helloworld.rb +25 -1
- data/exe/scad +10 -0
- data/fonts/font1.txt +666 -0
- data/fonts/font2.txt +1521 -0
- data/fonts/font3.txt +1046 -0
- data/fonts/font4.txt +951 -0
- data/lib/scad/cli.rb +1092 -0
- data/lib/scad/compiler.rb +520 -0
- data/lib/scad/decompiler.rb +234 -0
- data/lib/scad/error.rb +58 -0
- data/lib/scad/formatter/buffer.rb +388 -0
- data/lib/scad/formatter/font.rb +355 -0
- data/lib/scad/formatter/line.rb +311 -0
- data/lib/scad/formatter.rb +278 -0
- data/lib/scad/source.rb +267 -0
- data/lib/scad/version.rb +69 -0
- data/lib/scad.rb +146 -0
- data/scad.gemspec +234 -0
- metadata +26 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3219801b18bb36009781c5d7ac65650c64af6143f7096f88fa61a94c9add21ff
|
4
|
+
data.tar.gz: 1bdb22a5f1db69b817eaa8325e538cc79dc7b01cda873c1f00e17518c6256b79
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 749936fc180aa1175a741853de8706b748c4e59778b1d72ca3be5cb8e6c6195b950fbaa33aa10b06204e9e40e11220faa41a3183819aad61ccc7ec9159f7f5ca
|
7
|
+
data.tar.gz: 5258cb62beefbd19906b6b32447be0db6d59b391d407e45d57fb708548351a4c9e046c59460d0a6fb2bc5d33e5d57c3f46dc54d4489caf50f11adce18bec0a85
|
data/.rspec
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
--require sp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(-~_*(-~_*(-~_*_[_]+_)+_)))+_)))}[]}"]
|
data/Gemfile.lock
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
GEM
|
2
|
+
remote: https://rubygems.org/
|
3
|
+
specs:
|
4
|
+
coderay (1.1.3)
|
5
|
+
diff-lcs (1.5.0)
|
6
|
+
method_source (1.0.0)
|
7
|
+
pry (0.14.1)
|
8
|
+
coderay (~> 1.1)
|
9
|
+
method_source (~> 1.0)
|
10
|
+
rake (13.0.6)
|
11
|
+
rspec (3.11.0)
|
12
|
+
rspec-core (~> 3.11.0)
|
13
|
+
rspec-expectations (~> 3.11.0)
|
14
|
+
rspec-mocks (~> 3.11.0)
|
15
|
+
rspec-core (3.11.0)
|
16
|
+
rspec-support (~> 3.11.0)
|
17
|
+
rspec-expectations (3.11.1)
|
18
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
19
|
+
rspec-support (~> 3.11.0)
|
20
|
+
rspec-mocks (3.11.1)
|
21
|
+
diff-lcs (>= 1.2.0, < 2.0)
|
22
|
+
rspec-support (~> 3.11.0)
|
23
|
+
rspec-support (3.11.1)
|
24
|
+
|
25
|
+
PLATFORMS
|
26
|
+
arm64-darwin-21
|
27
|
+
|
28
|
+
DEPENDENCIES
|
29
|
+
pry
|
30
|
+
rake
|
31
|
+
rspec
|
32
|
+
|
33
|
+
BUNDLED WITH
|
34
|
+
2.3.15
|
data/README.md
CHANGED
@@ -7,23 +7,24 @@ _*_ [_] +_) )+_ ))) +_) +_)
|
|
7
7
|
(-~ _*( -~_ *_[ _]+ _)) ))) )++
|
8
8
|
_)<<(-~_*(-~_*( -~_*(-~_*(-~_*( -~_ *(- ~_*_[_]+_))))+_)))
|
9
9
|
```
|
10
|
-
[Run this code online](https://tio.run/##fZJBDgIhDEX3nKILkrEQ9QCiF5lMmngEExdu5ur4kcwMUPAvGmhL@I/yej8/MRKR3K29Wnuzj0sI00SbQjidV3FboFrIlduyMwW/GnHSnJllQfTCTZ790cnMTY/uhzODa6gn3E0Dwdi@3oEajoQC77mg8TVTSVYqu840Nas3@ryw75J2J5FDlxU1M5qVfjEnc6ouXrn56124MjT6A3uyOyF0CF4NyNAvxvgF)
|
11
10
|
|
12
11
|
# SCAD - Symbolic Compiler and Decompiler
|
13
12
|
|
14
|
-
SCAD is a Ruby to Ruby compiler (so technically it is a transpiler) which outputs code containing only symbols (in particular, it does not use letters and digits in the source). It also includes decompiler (detranspiler?) to reverse code to the original form.
|
13
|
+
SCAD is a Ruby to Ruby compiler (so technically it is a transpiler) which outputs code containing only symbols (in particular, it does not use letters and digits in the source). Code is formatted so it's shape looks like the original text. It also includes decompiler (detranspiler?) to reverse code to the original form.
|
15
14
|
|
16
|
-
[Here is hello world](examples/helloworld.rb) compiled by SCAD.
|
15
|
+
[Here is hello world](https://github.com/radarek/scad/raw/master/examples/helloworld.rb) compiled by SCAD.
|
17
16
|
|
18
17
|
## Usage
|
19
18
|
|
20
19
|
```shell
|
21
|
-
|
22
|
-
|
23
|
-
-i, --inplace Replace file in place
|
20
|
+
Usage: scad [options] [file ...]
|
21
|
+
-i, --inplace Replace file in place (back up file first to be safe!)
|
24
22
|
-c, --compile Compile file
|
25
23
|
-d, --decompile Decompile file
|
26
|
-
-a, --automatic
|
24
|
+
-a, --automatic Detect automatically and compile or decompile file
|
25
|
+
-f, --font=FONT Use specific font when formatting compiled code (default: font4.txt). See fonts/ directory.
|
26
|
+
-v, --version Show version
|
27
|
+
-h, --help Show this message
|
27
28
|
```
|
28
29
|
|
29
30
|
## Why does it exist?
|
@@ -37,15 +38,56 @@ I was inspired by [RubyConf 2017: Esoteric, Obfuscated, Artistic Programming in
|
|
37
38
|
```
|
38
39
|
|
39
40
|
I spent couple of minutes to understand how this code works.
|
40
|
-
After that, I thought that it
|
41
|
+
After that, I thought that it will be a fun idea to write a tool which automatically converts any Ruby code to this syntax.
|
41
42
|
|
42
43
|
## Does it work with any code?
|
43
44
|
|
44
|
-
The original code has some unexpected features, which
|
45
|
+
The original code has some unexpected features, which breaks any serious Ruby code:
|
45
46
|
|
46
47
|
* it changes `self` to the empty string
|
47
|
-
* it
|
48
|
+
* it injects additional local variables to the code
|
48
49
|
* `__FILE__` keyword (yes, [it is the keyword](https://github.com/ruby/ruby/blob/12883f8fa6222324880e2b0f161f8c6d6cf365c7/defs/keywords#L13)) returns `"(eval)"`
|
49
50
|
* `__dir__` method returns `nil`
|
50
51
|
|
51
52
|
To make it work with any Ruby code, I had to fix all of them.
|
53
|
+
|
54
|
+
To fix `self` reference, we just need to pass somehow `self` reference instead of empty string. We can't however do this directly - we would break the rule of not using letters and digits. The trick is to pass an additional parameter to our lambda. This parameter is yet another empty lambda `->{}`. Every lambda remembers its environment it was created in. It also includes `self`. It can be taken through `lambda.binding.receiver`. Of course, we still can't call it directly (remember the rule?) but now we can use the same trick with "eval-through-lambda" to evaluate this code. In our code, it will look like this:
|
55
|
+
|
56
|
+
```ruby
|
57
|
+
->(_, &__){
|
58
|
+
__[
|
59
|
+
__['', 'eval', '_.binding.receiver'],
|
60
|
+
'eval',
|
61
|
+
'p "Hello World!", self, local_variables, __FILE__, __dir__'
|
62
|
+
]
|
63
|
+
}[->{}, &:"#{'send'}"]
|
64
|
+
```
|
65
|
+
|
66
|
+
Next thing to fix are local variables. When we call `eval` there are some already defined local variables. Specifically `_` and `__`. They are accessible in the evaled code. It is not a big deal, but we want to get rid of them. To achieve this, we have to specify an additional argument - the binding. We have to create somehow empty binding. Unfortunately, Ruby does not allow creating it manually. It's not a problem. We can get it... from our new lambda (using `binding` method). Because it was created in outer scope and there are no local variables there, then it will be empty. We will use "eval-through-lambda" one more time:
|
67
|
+
|
68
|
+
```ruby
|
69
|
+
->(_, &__){
|
70
|
+
__[
|
71
|
+
__['', 'eval', '_.binding.receiver'],
|
72
|
+
'eval',
|
73
|
+
'p "Hello World!", self, local_variables, __FILE__, __dir__',
|
74
|
+
__['', 'eval', '_.binding'],
|
75
|
+
]
|
76
|
+
}[->{}, &:"#{'send'}"]
|
77
|
+
```
|
78
|
+
|
79
|
+
We are left with two last problems. `__FILE__` and `__dir__` returns `"(eval)"` in the code which is evaled. To fix this, we need to pass an additional argument to the `eval` so it will treat the code as it is run from the file. In outer scope we could pass original `__FILE__` to our lambda but... yes, the rule. As you probably already noticed, we use lambda for every problem we have, and it's not different this time. We can get source location by using `lambada.source_location[0]`:
|
80
|
+
|
81
|
+
```ruby
|
82
|
+
->(_, &__){
|
83
|
+
__[
|
84
|
+
__['', 'eval', '_.binding.receiver'],
|
85
|
+
'eval',
|
86
|
+
'p "Hello World!", self, local_variables, __FILE__, __dir__',
|
87
|
+
__['', 'eval', '_.binding'],
|
88
|
+
__['', 'eval', '_.source_location[0]'],
|
89
|
+
]
|
90
|
+
}[->{}, &:"#{'send'}"]
|
91
|
+
```
|
92
|
+
|
93
|
+
The final code has some more additional tricks, so code can be freely formatted. You can discover it on your own. Good luck!
|
data/Rakefile
ADDED
@@ -0,0 +1,47 @@
|
|
1
|
+
->(___,&__){_=$$/$$;____=%|
|
2
|
+
'' << (-~_*( - ~_* (-~_ *(- ~ _*(- ~
|
3
|
+
_*( -~_ *_[ _] +_) ))) +_)+ _)< <(- ~_*( -~_
|
4
|
+
*(-~_*(-~_*(-~ _*(-~_ *_[_ ]+_ ))))))< <(-~_*(- ~_*(-~_ *(-~ _*(- ~_*(-~_ *(-~_*_ [_]+ _)+ _))) +_)+ _))< <(-~_*(-~ _*( -~_* (-~_*(- ~_*(-~_ *(-~ _*_ [_]+_) +_) +_)))+_ ))<< (-~ _*(- ~_*( -~_*(-~
|
5
|
+
_*( -~_ *(- ~_*(-~_* _[_] +_)+ _))+_)+_ )+_) +_)< <(-~_*(-~_ *(-~ _* (-~ _*(-~_*( -~_* (-~_*_[_]+ _)+_ )+_) +_) )+_) )<< (-~_ *(-~ _*(-~_*( -~ _*(- ~_* (-~ _*(-~_*_ [_]+ _)+_ )))+ _))+
|
6
|
+
_)<<(-~_*(-~_* (-~ _*( -~_ *(- ~_*(- ~_*(-~_*_ [_] +_) +_))+_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~_*(-~_*_[_]+_)+_)+_)))+_)+_)<<(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*_[_]+_)+_)))+_))+_)<<(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*_[_]+_)+_))+_)+_)+_))<<(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*(-~_*_[_]+_)+_)))+_)))}[]}"]
|
data/examples/helloworld.rb
CHANGED
@@ -1 +1,25 @@
|
|
1
|
-
->(___,&__){_=$$/$$;
|
1
|
+
->(___,&__){_=$$/$$;____=%|
|
2
|
+
' '<< (-~ _*(-~ _*(-~ _*(- ~_*( -~_*(- ~_*(-~ _*_[ _]+_ )+_ )+_ ))) ))<
|
3
|
+
<(- ~_* (-~ _*(-~ _*(-~ _*(- ~_*( -~_*( -~_*_ [_] +_)+ _)+_ ))+ _)) +_)
|
4
|
+
<<(-~_*(- ~_*( -~_* (-~_*(- ~_*(-~_ *(- ~_* _[_]+_) +_) +_) )+_)))< <(-~_ *(-~_* (-~ _*(-~_* (-~_ *(- ~_* (-~_*_[_ ]+_
|
5
|
+
)+_) +_)) )+_) +_)< <(- ~_*( -~ _*(-~_*(-~_ *(-~ _*(- ~_* _[_ ]+_) )))) )<<( -~_*(-~_ *(- ~_*( -~_* (-~_*(-~ _*_ [_]+ _))) )+_
|
6
|
+
))< <(- ~_* (-~ _*( -~_*(-~ _*( -~_ *(-~_*(-~ _*_ [_] +_) ))+ _))))<< (-~_*(- ~_* (-~ _*( -~_ *(- ~_* (-~
|
7
|
+
_*( -~_ *_[ _]+ _)+ _ )) )+_) )+_ )<< (-~ _* (-~ _*( -~_ *(- ~_*(- ~_*(- ~_* (-~ _*_ [_] +_) +_) )+_
|
8
|
+
)+_)))<<( -~_*(-~_*( -~_*( -~_*(-~_ *(-~_ *(-~_ *_[_]+_)+ _))+_ )+_)) )<<(-~_*( -~_ *(- ~_*(-~_*( -~_*( -~_*( -~_*_[_]+_ )+_
|
9
|
+
))+
|
10
|
+
_)+_)
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