Skip to content

using keyword extension#11

Open
inky03 wants to merge 3 commits intopisayesiwsi:devfrom
inky03:using
Open

using keyword extension#11
inky03 wants to merge 3 commits intopisayesiwsi:devfrom
inky03:using

Conversation

@inky03
Copy link
Copy Markdown

@inky03 inky03 commented Dec 24, 2024

allows the static extension using keyword to be used for any class; also an attempt to improve its behavior

  • using the keyword will also import the class, as intended
  • prioritizes checking if a function exists on the object before checking if it exists in an extension
  • also adds a type check function to UsingEntry, helpful to enhance currently existing entries in allUsings and also to prevent the interpreter from failing if a function has a null return value (ex. using Lambda, <Iterable>.find returning null if it doesn't find a matching item)

i also updated the stringtools test asset to reflect some of these changes

@crowplexus crowplexus requested a review from NeeEoo December 24, 2024 04:01
@NeeEoo
Copy link
Copy Markdown
Contributor

NeeEoo commented Dec 24, 2024

@crowplexus how do we change this to dev branch? Or is this synced with the latest version? Because my moved code we did isnt here

@NeeEoo
Copy link
Copy Markdown
Contributor

NeeEoo commented Dec 24, 2024

Wait this is already dev branch

@NeeEoo
Copy link
Copy Markdown
Contributor

NeeEoo commented Dec 24, 2024

Ohhh @crowplexus you forgot to push your local changes

@crowplexus
Copy link
Copy Markdown
Collaborator

Ohhh @crowplexus you forgot to push your local changes

I will push it soon

default: false;
}
}),
new UsingEntry("Lambda", function(o: Dynamic, f: String, args: Array<Dynamic>): Dynamic {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had it as a string to allow people make custom usings,

but please do wait until we push our local changes

@crowplexus
Copy link
Copy Markdown
Collaborator

updated master and dev branches

@pisayesiwsi pisayesiwsi added the topic:feature New feature or request label Jul 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

topic:feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants