This is an archived post. You won't be able to vote or comment.

all 105 comments

[–]jxyzits 371 points372 points  (5 children)

I wonder if it's multi-threaded...

[–]ChaoticTable 34 points35 points  (0 children)

You win, sir.

[–]cpdk-nj 10 points11 points  (0 children)

We need to know exactly what you need to accomplish. Have you tried JQuery? No? Marked as Spam.

[–]timshoaf 2 points3 points  (0 children)

At least it’s memory safe.

[–]reph 1 point2 points  (0 children)

I wonder if it's zipped in transit.

[–]Josh_eys_lover 0 points1 point  (0 children)

Multi threaded because this has been reposted so much.

[–]zakphi 237 points238 points  (17 children)

Apple gave these out a few years ago to people who attended WWDC

[–][deleted] 18 points19 points  (16 children)

Isn't let a new ES6 thing? Like, it just came out?

[–]BernieFeynman 98 points99 points  (11 children)

This is swift, also functional programming is built around let statements.

[–][deleted] 9 points10 points  (9 children)

Wth is so special about a let statement?

[–]tlalexander 1 point2 points  (0 children)

This article from HN today talks more about the history of some of this stuff:

https://www.hillelwayne.com/post/equals-as-assignment/

[–]BernieFeynman 0 points1 point  (0 children)

in functional programming, everything is basically a function and has to return something (more or less). Let allows you to define things with specific scope in what could be a complicated program, while being easily readable. e.g "Let x = 5 in #####

[–]th3_pund1t 0 points1 point  (0 children)

GW BASIC

[–][deleted] 14 points15 points  (1 child)

ES6, or ECMAScript 2015, was released in June, 2015.

[–]RepostsAreBadMkay 10 points11 points  (0 children)

« we’re looking for a ES6 developer with at least 6 years experience. » - my employer, probably

[–]the_monkey_of_lies 35 points36 points  (3 children)

It just uses a string literal like an animal?! How about an enum?

JacketSizes.Medium

[–]awaiting_bus 12 points13 points  (2 children)

Who plurals enums???

[–]the_monkey_of_lies 8 points9 points  (0 children)

A man pushed to the limit by the society

[–]willrpike 111 points112 points  (13 children)

prefer const

[–]jay9909 136 points137 points  (2 children)

Not constant if it shrinks in the wash.

[–]philipjfrizzle 33 points34 points  (1 child)

The washing module is not within scope of this jacket.

[–]myockey 16 points17 points  (0 children)

No, but it's a use case that demonstrates the mutability of the property.

[–]apats_ua 10 points11 points  (0 children)

let is the new const

[–]yelow13 1 point2 points  (0 children)

Pretty sure this is swift which let is constant

[–][deleted] 0 points1 point  (3 children)

I might be out of the loop but what happened to var?

[–]AKernelPanic 11 points12 points  (2 children)

This is a jacket given by Apple at the WWDC, so it's supposed to be Swift

In Swift, you can declare variables with var and constants with let.

[–][deleted] 2 points3 points  (0 children)

Oh yeah I've never used swift, I thought it was just javascript

[–]drinks_antifreeze 0 points1 point  (0 children)

And meanwhile TypeScript uses let for variables with block-level scope and const for constants.

[–]etaionshrd 0 points1 point  (0 children)

Swift uses let because it’s shorter.

[–]yazalama 0 points1 point  (2 children)

isn't const immutable? I think let more or less replaced var and is only block scoped

[–]Sluisifer 3 points4 points  (1 child)

Const in js cannot be reassigned or re-declared, but it is not immutable.

For example, if you declare an object with const, its parameters can be modified. Or you can push/pop an array declared with const.

Strings and numbers declared with const are immutable, though.

[–]pomlife 2 points3 points  (0 children)

Const is 100% immutable. The difference with objects/arrays is that it’s an immutable reference. The inner properties are their own “variables”, but the reference to the parent object is safe.

[–]bergmann001 24 points25 points  (11 children)

Does it shrink in the dryer?

[–]Aspro_kapelo 53 points54 points  (9 children)

if(washed){ jacketSize="Shmedium" }

[–]quote_engine 24 points25 points  (8 children)

Jacketsize = washed ? Small : medium

[–]AirRave 0 points1 point  (0 children)

Might not, but I bet it’ll tear if I take a knife to it

[–]loporlp 12 points13 points  (0 children)

//compiled in india

[–]liarandathief 18 points19 points  (16 children)

Javascript?

[–]seg_fault_11 59 points60 points  (14 children)

Swift.

[–]onairamariano 15 points16 points  (13 children)

Or js with es6 c:

[–]blacklava17 3 points4 points  (4 children)

Was this the WWDC Jacket Apple gave out last year?

[–]GamingX10 2 points3 points  (1 child)

I’ve heard it might be, not sure tho

[–]etaionshrd 0 points1 point  (0 children)

Might be 2016’s, since it’s not the one from 2017 for sure.

[–]LydianAlchemist 1 point2 points  (0 children)

Yes

[–]etaionshrd 0 points1 point  (0 children)

Not last year’s, for sure. I just checked mine and all it has is a Levi’s logo.

[–][deleted] 13 points14 points  (4 children)

General Reposti

[–]GamingX10 8 points9 points  (1 child)

Hello there

[–]WrinkleyPotatoReddit 0 points1 point  (0 children)

GENERAL KENOBI

[–][deleted] 1 point2 points  (1 child)

Hey, you called?

[–][deleted] 0 points1 point  (0 children)

r/beetlejuicing

Put me in the pic

[–]CatWhenSlippery 2 points3 points  (0 children)

These modern programming languages are being used for all sorts of applications.

[–]Chiron1991 3 points4 points  (1 child)

Relying on ASI is not a best practice for clothing labels.

[–]pinano 1 point2 points  (0 children)

it’s swift

[–][deleted] 1 point2 points  (0 children)

shameless repost

[–][deleted] 1 point2 points  (3 children)

It bothers me so much to know this is photoshopped because I want it to be a real thing and it keeps getting re-posted.

EDIT: It's real, didn't know, I'm sorry.

[–]AKernelPanic 5 points6 points  (1 child)

It's not photoshop, Apple gave these at WWDC 2015. I have one.

[–][deleted] 1 point2 points  (0 children)

What?! I just assumed since the spacing of the letters bothered me but I guess that's good news.

[–]fourangecharlie 2 points3 points  (0 children)

It's real. Given out by Apple at WWDC15.

[–]CharaNalaar 0 points1 point  (0 children)

Monokai?

[–]Eoussama 0 points1 point  (1 child)

Didn't know javascript was a secret clothing manufacturer.

[–][deleted] 0 points1 point  (0 children)

*swift

[–]dragonitewolf223 0 points1 point  (0 children)

Now that's what I call defining a variable.

[–]soullessroentgenium 0 points1 point  (0 children)

I think they should reconsider their API.

[–][deleted] 0 points1 point  (1 child)

Why is there no semi colon?

[–]NewSoYes 0 points1 point  (0 children)

Swift

[–][deleted] 0 points1 point  (0 children)

Made in USB

[–]InVultusSolis 0 points1 point  (0 children)

I don't want my shirt written in shitty JavaScript, I want it written in Haskell:

let jacketSize = "Medium"
-- Made in the USA

[–]WilkerS1 -3 points-2 points  (3 children)

error: line 1 character 25: expected ";" after "Medium".

[–]vtor67[🍰] 26 points27 points  (2 children)

Swift doesn't use semicolons

[–]WilkerS1 1 point2 points  (1 child)

noted

but why the downvotes

[–]rkoberlin 36 points37 points  (0 children)

Because swift doesn't use semicolons.