(varname)
| 266 | return true; |
| 267 | } |
| 268 | function register(varname) { |
| 269 | function inList(list) { |
| 270 | for (var v = list; v; v = v.next) |
| 271 | if (v.name == varname) return true; |
| 272 | return false; |
| 273 | } |
| 274 | var state = cx.state; |
| 275 | if (state.context) { |
| 276 | cx.marked = "def"; |
| 277 | if (inList(state.localVars)) return; |
| 278 | state.localVars = {name: varname, next: state.localVars}; |
| 279 | } else { |
| 280 | if (inList(state.globalVars)) return; |
| 281 | if (parserConfig.globalVars) |
| 282 | state.globalVars = {name: varname, next: state.globalVars}; |
| 283 | } |
| 284 | } |
| 285 | |
| 286 | // Combinators |
| 287 |
no test coverage detected