generall / aligner_atom

GitHub Atom plugin for automatic code alignment.
MIT License
1 stars 0 forks source link

Lambda handling #2

Open firedev opened 10 years ago

firedev commented 10 years ago

It might be language-specific, but still, it explodes lambdas in ruby:

Before:

scope :with_type, -> { includes :type }
scope :with_images, -> { includes :images }

After:

scope :with_type     , - > { includes :type     }
scope :with_images   , - > { includes :images   }
generall commented 10 years ago

Yes, it is language-specific. Ruby is not supported yet.

firedev commented 10 years ago

In fact aligning PHP method calls end up the same, -> used in PHP as well.

Also I am not sure it has to add extra spaces before the comma. I.e. it should be:

whatever,     -> { }

instead of:

whatever   ,  -> { }
firedev commented 10 years ago

Sorry, accidentally closed this.