• janAkali@lemmy.one
    ·
    edit-2
    1 year ago

    Not a language per se, but subsets of languages used for fantasy consoles usually do not implement import functionality. TIC-80, PICO-8, etc. etc. WIKI I wouldn't call that a feature, but it drives you to write less and more space-optimized code.
    Now that I think about it, source code size could be a feature in itself, look at codeGolf-oriented esolangs:

    • Pyth
    • CJam
    • GolfScript
    • Microscript/Microscript II
    • Seriously
    • Rotor
    • Minkolang
    • Gaia
    • Jelly
    • 05AB1E
    • japt
    • and more...
    • snek_boi@lemmy.ml
      hexagon
      ·
      1 year ago

      I know encapsulation is desirable in part because of security. I figured something similar could happen by removing the ability to import anything from another program. However, I struggled to think about other situations in which no imports were desirable, and so I wondered…

      • Ethan@programming.dev
        ·
        1 year ago

        There are certainly situations where it would be valuable to be able to place limits on what can be imported, but I can't imagine trying to work with a language that was completely devoid of imports. Because that would mean 100% of your source would have to be in a single file, which sounds absolutely awful for anything but the most trivial applications.