Skip to content

Instantly share code, notes, and snippets.

@brendansudol
Created March 31, 2017 18:05
Show Gist options
  • Select an option

  • Save brendansudol/7eadcd92df0431eb893ff0c78046b579 to your computer and use it in GitHub Desktop.

Select an option

Save brendansudol/7eadcd92df0431eb893ff0c78046b579 to your computer and use it in GitHub Desktop.
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@thecapacity
Copy link

I had to look up the behavior of self.keys = GH_KEYS[:] ?

I was pretty sure it was to make a copy but had never seen the "slice as copy" before, apparently I'm not alone; http://stackoverflow.com/questions/2612802/how-to-clone-or-copy-a-list

it is a weird syntax and it does not make sense to use it ever 😂

Love seeing your code, thanks for teaching me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment