# Feature request

**URL:** <https://www.ruby-forum.com/t/feature-request/100992>\
**Category:** Rails\
**Created:** [August 2, 2006, 3:59pm UTC](https://www.ruby-forum.com/t/feature-request/100992 "2006-08-02T15:59:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bartels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bbce88/32.png) [@bartels](https://www.ruby-forum.com/u/bartels)\
**Post date:** [August 2, 2006, 3:59pm UTC](https://www.ruby-forum.com/t/feature-request/100992/1 "2006-08-02T15:59:23Z")

</div>

Is there a place for feature requesting?

Rails uses the “@” prefix for vars in the request scope, why not add a  
prefix for the session scope? Instead of “session[:myvar]” it could then  
be something like “%myvar”.

---

<div class="post-metadata">

**Author:** ![bartels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bbce88/32.png) [@bartels](https://www.ruby-forum.com/u/bartels)\
**Post date:** [August 2, 2006, 8:43pm UTC](https://www.ruby-forum.com/t/feature-request/100992/2 "2006-08-02T20:43:49Z")

</div>

Bart E. wrote:

> Rails uses the “@” prefix for vars in the request scope…

It’s not so much that “Rails uses a prefix” in this case. The @ is all  
Ruby; it indicates the identifier is an object-level variable. This  
enables Rails to do whatever meta-magic it does to push them down into  
the view. (If they were without the @, they would go out of scope upon  
leaving the action. Try it.)

session, cookies and params aren’t variables. They’re methods. So of  
course they don’t have a “prefix.” (Granted I believe you can still call  
@session, but it’s deprecated.)

- Daniel

---

<div class="post-metadata">

**Author:** ![bartels](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/b/bbce88/32.png) [@bartels](https://www.ruby-forum.com/u/bartels)\
**Post date:** [August 3, 2006, 12:39pm UTC](https://www.ruby-forum.com/t/feature-request/100992/3 "2006-08-03T12:39:57Z")

</div>

Hi –

On Wed, 2 Aug 2006, Bart E. wrote:

> Is there a place for feature requesting?
> 
> Rails uses the “@” prefix for vars in the request scope, why not add a  
> prefix for the session scope? Instead of “session[:myvar]” it could then  
> be something like “%myvar”.

That’s not valid Ruby. @var is a Ruby instance variable, which is  
what Rails uses for controller \<=\> template communication.

David

–  
[http://www.rubypowerandlight.com](http://www.rubypowerandlight.com) =\> Ruby/Rails training & consultancy  
----\> SEE SPECIAL DEAL FOR RUBY/RAILS USERS GROUPS! \<-----  
[http://dablog.rubypal.com](http://dablog.rubypal.com) =\> D[avid]A[.]B[lack’s][Web]log  
[Ruby for Rails](http://www.manning.com/black) =\> book, Ruby for Rails  
[http://www.rubycentral.org](http://www.rubycentral.org) =\> Ruby Central, Inc.
