Support paths to names rather than just raw idents (#5778)
* Support paths to names rather than just raw idents Signed-off-by: Nick Cameron <nrc@ncameron.org> * A snapshot a day keeps the bugs away! 📷🐛 * A snapshot a day keeps the bugs away! 📷🐛 * A snapshot a day keeps the bugs away! 📷🐛 * A snapshot a day keeps the bugs away! 📷🐛 --------- Signed-off-by: Nick Cameron <nrc@ncameron.org> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
import { BinaryPart } from '../lang/wasm'
|
||||
import {
|
||||
createIdentifier,
|
||||
createLocalName,
|
||||
createLiteral,
|
||||
createUnaryExpression,
|
||||
} from '../lang/modifyAst'
|
||||
@ -151,7 +151,7 @@ export function removeDoubleNegatives(
|
||||
variableName?: string
|
||||
): BinaryPart {
|
||||
let finValue: BinaryPart = variableName
|
||||
? createIdentifier(variableName)
|
||||
? createLocalName(variableName)
|
||||
: valueNode
|
||||
if (sign === -1) finValue = createUnaryExpression(finValue)
|
||||
if (
|
||||
|
Reference in New Issue
Block a user