Thread: [Objectscript-devel] [OBJECTSCRIPT] Issue #OBJS38 modified
Brought to you by:
rob_d_clark
From: Rob C. <rob...@ma...> - 2003-02-12 01:22:50
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: Added 'blocking' child dependency on issue OBJS38 Added 'blocking' parent dependency on issue OBJS39 |
From: Rob C. <rob...@ma...> - 2003-05-09 18:44:34
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: On another PR (OBJS112) I made the changes to the function scope... I just removed the BasicScope, so the only scope created when calling a function is the FunctionScope, which means args to a function exist in the same scope as local variables. This doesn't change the current behavior. The area that does need to be addressed is scope in the case of calling a function as constructor/extends. In both those cases, we create a ConstructorScope whose parent is the ScriptObject scope that is the object being constructed. The reason for this, is to insulate code (and functions declared within) the constructor function from arguments to parent class constructor, which is a good thing, but is about as elegant as bondo, since you can't do things like: function Foo(a) { public function setA(a) { this.a = a; } } since the argument "a" to Foo is not a member of the object, but instead a member of the ConstructorScope. (To work-around, people end up doing things like "a = _a".) The solution is to make "this" generated by the ConstructorScope, instead of the ScriptObject scope, and make "this" behave as the union of the ConstructorScope and the ScriptObject scope. Also, the ConstructorScope should ensure that no members are created in it's parent ScriptObject scope that would be eclipsed by members of itself (ie. args to the constructor function) This change would effect some .os code, but it is easy enough to detect by writing a little script (that uses ExtensibleVisitor) to parse src files and detect places where the change may result in altered behavior. It won't be possible to tell which functions are going to be called as constructor vs. as a function, but we can rely on some heuristics, such as the capitolization of the function's name (if it is not anon), and the presence of public members. |
From: Rob C. <rob...@ma...> - 2003-05-09 18:48:04
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: oh, duh... I'm retarted... I don't need any heuristics for the script to detect places where behavior changes... I only need to look for places where there is a local var and argument with the same name. |
From: Rob C. <rob...@ma...> - 2003-05-09 18:58:23
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: oh, and this would also let me add "private" modifier... a private var would be a member of the ConstructorScope rather than the ScriptObject scope |
From: Rob C. <rob...@ma...> - 2003-05-12 21:33:55
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: Status changed from 'New' to 'Assigned' Comment: move to 'assigned' state |
From: Rob C. <rob...@ma...> - 2003-05-12 22:50:56
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: Description changed from 'I want to do some re-arra...' to 'I want to do some re-arra...' Comment: slight update to the description |
From: Rob C. <rob...@ma...> - 2003-05-13 00:35:58
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: added file 'check-scope.os' at mod100/0/OBJS38_807_check-scope.os |
From: Rob C. <rob...@ma...> - 2003-05-13 01:25:26
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: added file 'check-scope.os' at mod100/0/OBJS38_809_check-scope.os |
From: Rob C. <rob...@ma...> - 2003-05-17 17:23:24
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: Status changed from 'Assigned' to 'Resolved' Comment: move to 'resolved' state |
From: Rob C. <rob...@ma...> - 2003-05-19 20:51:05
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: deleted attachment for file 'check-scope.os'; path=mod100/0/OBJS38_809_check-scope.os |
From: Rob C. <rob...@ma...> - 2003-05-19 20:59:41
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: added file 'check-scope.os' at mod100/0/OBJS38_833_check-scope.os |
From: Rob C. <rob...@ma...> - 2003-05-22 01:36:42
|
Issue OBJS38 (scope tweak) has just been modified by user rob...@ma... You can view the issue detail at the following URL: <http://icandy.homeunix.org:443/scarab/issues/id/OBJS38> The following modifications were made to this issue: Status changed from 'Resolved' to 'Closed' Comment: oscript-1.2 |