Skip to content

Commit 67dd4b5

Browse files
committed
upd
1 parent 0d15d99 commit 67dd4b5

148 files changed

Lines changed: 630 additions & 1801 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737
- name: Install mdbook
3838
run: |
3939
mkdir bin
40-
curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.4.49/mdbook-v0.4.49-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=bin
40+
curl -sSL https://github.com/rust-lang/mdBook/releases/download/v0.5.2/mdbook-v0.5.2-x86_64-unknown-linux-gnu.tar.gz | tar -xz --directory=bin
4141
- name: Build reference portal
4242
run: bin/mdbook build
4343
- name: Git commit report

TODO

Lines changed: 66 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,19 @@
44
- [ ] Describe operations like GetQNameInNsSetOrAnyPublicNs() and possibly others used in property lookup
55
- [70%] Property lookup
66
- https://github.com/whackengine/sdk/blob/master/crates/mxmlsemantics/src/semantics/property_lookup.rs#L353
7-
- [x] PropertyLookup: remind of `shock_proxy` stuff
8-
- [x] `shock_proxy::get` allows for multiple signatures
7+
- [x] PropertyLookup: remind of `meta` stuff
8+
- [x] `meta::get` allows for multiple signatures
99
- [ ] Introduce lazily imported source files based in source paths, when lookuping from packages.
1010
- [ ] Values whose static type is a type parameter will lookup for names in the type parameter's derived types.
1111
- [ ] InScopeLookup
1212
- [ ] Introduce lazily imported source files based in source paths.
13-
- [ ] `DotEnv` qualifier causes DotEnv variable retrieval.
13+
- [ ] `env` qualifier causes DotEnv variable retrieval (or, depending on the implementation, may resolve to a predefined variable).
1414
- [ ] Use `fixed=true` access when doing property lookup in activation's `this` (e.g. user should use `this` if the enclosing class is dynamic and needs to access a dynamic property).
1515
- [ ] Constants
1616
- [ ] *EnumConstant* for both regular enumerations and flag enumerations
1717
- [ ] Reference values
1818
- [ ] *DynamicReferenceValue*(*base*, *qual*, *key*.Value, *followedByCall*, *fixed*)
19-
- [ ] *KeyValuePairReferenceValue*(*base*, *proxy method*, *qual*, *key*)
19+
- [ ] *KeyValuePairReferenceValue*(*base*, *meta-method*, *qual*, *key*)
2020
- [ ] Do not include XML reference values from Whack Engine
2121
- [70%] Packages
2222
- [70%] Namespaces
@@ -31,8 +31,8 @@
3131
- [x] Lexical scopes
3232
- [x] Default lexical scope
3333
- [x] Conditional compilation
34-
- [x] ShockDoc comments
35-
- [x] Proxies
34+
- [x] ESDoc comments
35+
- [x] Meta-methods
3636
- [x] Lexical conventions
3737
- [ ] ShockScript: Expressions
3838
- [x] `Embed()`
@@ -63,18 +63,17 @@
6363
- [ ] Takes a non-attribute qualified identifier.
6464
- [ ] Call operator
6565
- [ ] Base is passed *followedByCall=true*
66-
- [ ] Watch for static `shock_proxy::call` when calling classes (supports multiple signatures too)
67-
- [ ] Take in consideration compatible overrides and overloads (also important for the `[object Object].equals()` method (e.g. in case two types are entirely different, should use the basemost `.equals()` method (essentially a dummy `===` comparison)))
68-
- [ ] `XML` and `XMLList` being called statically shall still pass themselves as the context type to the first call argument, even if they define `shock_proxy::call()`.
66+
- [ ] Watch for static `meta::call` when calling classes (supports multiple signatures too)
67+
- [ ] `XML` and `XMLList` being called statically shall still pass themselves as the context type to the first call argument, even if they define `meta::call()`.
6968
- [ ] Perform type inference for omitted generic parameters.
7069
- [ ] `v as T` operator
7170
- [ ] Passes context type `T` to `v`
7271
- [ ] Assignment expression
73-
- [ ] When base is *KeyValuePairReferenceValue*, `shock_proxy::set()`
74-
- [ ] When base is *AttributeReferenceValue*, `shock_proxy::setAttribute()`
72+
- [ ] When base is *KeyValuePairReferenceValue*, `meta::set()`
73+
- [ ] When base is *AttributeReferenceValue*, `meta::setAttribute()`
7574
- [ ] Delete operator
76-
- [ ] `shock_proxy::delete()`
77-
- [ ] `shock_proxy::deleteAttribute()`
75+
- [ ] `meta::delete()`
76+
- [ ] `meta::deleteAttribute()`
7877
- [ ] New operator
7978
- [ ] Base is passed *followedByCall=true*
8079
- [ ] Support a dynamically typed base (`*` or `Class`)
@@ -94,12 +93,16 @@
9493
- [x] ShockScript: Definitions
9594
- [ ] Semantics
9695
- [ ] Global objects
97-
- [ ] shock_proxy namespace
98-
- [ ] DotEnv namespace
99-
- [ ] Reflect namespace
96+
- [ ] (Whack engine) w namespace = "http://www.sweaxizone.com/whack/2015"
97+
- [ ] ES4 namespace = "http://www.sweaxizone.com/shockscript/2015/global"
98+
- [ ] Intl namespace = "org.shockscript.intl"
99+
- [ ] Temporal namespace = "org.shockscript.temporal"
100+
- [ ] env namespace (DotEnv special qualifier) = "http://www.sweaxizone.com/shockscript/2015/env"
101+
- [ ] reflect namespace = "http://www.sweaxizone.com/shockscript/2015/reflect"
100102
- [ ] trace()
103+
- [ ] etrace()
101104
- [ ] assert()
102-
- [ ] assertEquals() (uses `[object Object].equals()` if each operand `is Object`)
105+
- [ ] assertEqual() (uses `equal()`)
103106
- [ ] assertThrows()
104107
- [ ] encodeURI()
105108
- [ ] decodeURI()
@@ -113,81 +116,81 @@
113116
- [ ] NaN
114117
- [ ] undefined
115118
- [ ] Iterator.\<T> (interface)
116-
- [ ] required `next():{ done: Boolean, value?: T }`
119+
- [ ] required `next():[T]?` (the returned array must be of length 1)
117120
- [ ] `length():int` (consumes the whole iterator)
118121
- [ ] `skip(count:int):void`
119-
- [ ] `shock_proxy::filter(...)` (returns another iterator)
122+
- [ ] `meta::filter(...)` (returns another iterator)
120123
- [ ] Other functional methods (iterator *helper methods* like `map`, `every`, `some`, `reduce`...)
121124
- [ ] Iterable.\<K, V> (interface) requires keys() and values()
122125
- [ ] Generator.\<T>
123126
- [ ] Comparable interface
124-
- [ ] `compareTo(obj:this):int`
125-
- [ ] This is used by default on array sorting (as long as element types are equal)
127+
- [ ] `compareTo(obj:Object):int`
128+
- [ ] This is used by default on array sorting.
126129
- [ ] Object
127-
- [ ] Reflect::class()
128-
- [ ] clone() returns `this`
129-
- Default implementation clones most objects fine (records, tuples, arrays, maps and so on), but classes with a required constructor will require a custom clone() override.
130-
- [ ] `equals(obj:this):Boolean`
131-
- May be used in addition to reference equality (==, ===). Default object behavior is ===.
132-
- Incompatible operands should use the most compatible base `.equals()` method (call operator specific behavior)
133-
- Floating points should have an `equals()` implementation done like in React.js's memoization/state new value comparison.
134-
- [ ] `Map.equals()` should look structurally using inner `.equals()`
135-
- [ ] Array too
136-
- [ ] Tuples too
137-
- [ ] Records too
130+
- [ ] `clone(deep:boolean=):Object`
131+
- \[protected]
132+
- Default implementation clones most objects fine (records, tuples, arrays, maps and so on), but fails for classes with a required constructor.
133+
- Clones are shallow (not deep) by default
134+
- [ ] `equals(obj:Object):boolean`
135+
- [ ] NaN = NaN
136+
- [ ] Maps
137+
- [ ] Array
138+
- [ ] Tuples
139+
- [ ] Records
140+
- [ ] Maps
141+
- [ ] (Other objects just use ===)
142+
- [ ] `reflect::class()`
138143
- [ ] toString()
139144
- [ ] toLocaleString()
140145
- [ ] valueOf()
141146
- [ ] Array
142-
- [ ] `shock_proxy::get(...)` throws if out of bounds
143-
- [ ] `shock_proxy::filter(...)`
144-
- [ ] `clone()`
147+
- [ ] `meta::get(...)` throws if out of bounds
148+
- [ ] `meta::filter(...)`
149+
- [ ] `clone(deep=)`
145150
- [ ] `shift(): (void, T)`
146151
- [ ] `pop(): (void, T)`
147152
- [ ] `first : (void, T)`
148153
- [ ] `last : (void, T)`
149154
- [ ] Map
150-
- [ ] `Map(weakKeys:Boolean = false)`
151-
- [ ] `shock_proxy::get()` throws if key does not match
155+
- [ ] `Map(weakKeys:boolean = false)`
156+
- [ ] `meta::get()` throws if key does not match
152157
- [ ] `length()`
153158
- [ ] `clear()`
154-
- [ ] `clone()`
155-
- [ ] String
156-
- [ ] static `fromByte(...):String`
157-
- [ ] `format(vars:Map.<String, String>):String`
159+
- [ ] `clone(deep=)`
160+
- [ ] string
161+
- [ ] static `fromByte(...):string`
162+
- [ ] `format(vars:Map.<string, string>):string`
158163
- Formats `$varName`, `${varName}` and `$$`
159164
- [ ] Chars
160-
- [ ] `new Chars(str:String, offset:int = 0)`
165+
- [ ] `new Chars(str:string, offset:int = 0)`
161166
- [ ] Indexing (peeking using zero-based Unicode code point positions; returns U+00 if out of bounds)
162-
- [ ] `seq(numCodePoints:int):String` (stops on end of stream)
167+
- [ ] `seq(numCodePoints:int):string` (stops on end of stream)
163168
- [ ] `peek():uint` (equivalent to `chars[0]`)
164-
- [ ] `reachedEnd:Boolean`
165-
- [ ] `hasRemaining:Boolean`
166-
- [ ] `clone():Chars`
169+
- [ ] `reachedEnd:boolean`
170+
- [ ] `hasRemaining:boolean`
171+
- [ ] `clone(deep=):Chars`
167172
- [ ] RegExpMatches
168173
- [ ] Implement indexing
169-
- [ ] `substr : [String]`
170-
- [ ] `clone()`
174+
- [ ] `substr : [string]`
175+
- [ ] `clone(deep=)`
171176
- [ ] XML
172177
- [ ] Implement `Iterable`
173-
- [ ] static `shock_proxy::call(arg:*):XML`
174-
- [ ] `shock_proxy::has(name:QName):Boolean`
175-
- [ ] `shock_proxy::get(index:int):XML` (throws if out of bounds)
176-
- [ ] `shock_proxy::get(name:QName):XMLList`
177-
- [ ] `shock_proxy::set(key:(int, QName), value:(XML, XMLList)):void`
178-
- [ ] `shock_proxy::delete(arg:(int, QName)):Boolean`
178+
- [ ] static `meta::call(arg:*):XML`
179+
- [ ] `meta::has(name:QName):boolean`
180+
- [ ] `meta::get(index:int):XML` (throws if out of bounds)
181+
- [ ] `meta::get(name:QName):XMLList`
182+
- [ ] `meta::set(key:(int, QName), value:(XML, XMLList)):void`
183+
- [ ] `meta::delete(arg:(int, QName)):boolean`
179184
- [ ] Attributes
180185
- [ ] XMLList
181-
- [ ] static `shock_proxy::call(arg:*):XMLList`
186+
- [ ] static `meta::call(arg:*):XMLList`
182187
- [ ] ByteArray
183188
- [ ] Indexing
184-
- [ ] `shareable:Boolean`
185-
- [ ] `clone()`
186-
- [ ] shock.intl.*
189+
- [ ] `shareable:boolean`
190+
- [ ] `clone(deep=)`
191+
- [ ] org.shockscript.intl.*
187192
- [ ] Like ECMA-262 `Intl`. Aliased `Intl::`, as well.
188-
- [ ] shock.temporal.*
193+
- [ ] org.shockscript.temporal.*
189194
- [ ] Like ECMA-262 like `Temporal`. Aliased `Temporal::`, as well.
190-
- [ ] shock.reflection.global.*
191-
192-
- Used for what the `Reflect` namespace cannot be used for. Aliased `GlobalReflection::`, as well.
193-
195+
- [ ] org.shockscript.reflect.*
196+
- Used for what the `reflect` namespace cannot be used for (e.g. perhaps extracting a list of properties from a package name).

book.toml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
[book]
2-
authors = ["hydroperx"]
2+
authors = ["MatheusDS4"]
33
language = "en"
4-
multilingual = false
54
src = "src"
65
title = "ShockScript Language Specification"
76

87
[output.html]
9-
copy-fonts = false
108
fold = { enable = true }

0 commit comments

Comments
 (0)