rokucommunity / rokucommunity/brighterscript

Conditional compile within associative array causes issues

Open
#1,302 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
208
Forks
68
Avg merge
8h 39m
Merged PRs (30d)
39

Description

This is valid code. We spoke in #1023 about not supporting this, but I'd love to at least think about how we could possibly support this

function test()
    return {
        name: "bob"
        #if true
            getSomething: sub()
                return "something"
            end sub
        #end if
    }
end function

image

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading this issue and the referenced discussion in #1023, then trace how conditional compilation and associative-array literals are handled. The issue does not name files or tests; the work is not complete until the project has an agreed approach for supporting or rejecting the shown example.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.