arturo-lang / arturo

Simple, expressive & portable programming language for efficient scripting
http://arturo-lang.io
MIT License
703 stars 32 forks source link

Sanitize File\exists? + add missing stdlib function #1570

Closed drkameleon closed 7 months ago

drkameleon commented 7 months ago

Description

Right now, we have exists?, which works in the following way:

That sounds a bit confusing. (See here: https://discord.com/channels/765519132186640445/829324913097048065/1208304920957157386)

Basically, if we want to check if a given path is a directory, we'd have to do exists?.directory - which is correct, although it's not ultra-intuitive.

What this PR is going to do is:

Type of change

drkameleon commented 7 months ago

Ready to merge! 🚀