Giter VIP home page Giter VIP logo

Comments (11)

MSch avatar MSch commented on June 8, 2024

I don't see why the blankslate gem is still necessary now that Ruby 1.9 has BasicObject

from jbuilder.

dhh avatar dhh commented on June 8, 2024

Feel free to whip up a patch!

On Sep 10, 2012, at 9:15 AM, Martin Schürrer [email protected] wrote:

I don't see why the blankslate gem is still necessary now that Ruby 1.9 has BasicObject


Reply to this email directly or view it on GitHub.

from jbuilder.

SamSaffron avatar SamSaffron commented on June 8, 2024

not that easy @MSch

  define_method(:__class__, find_hidden_method(:class))
  define_method(:_tap, find_hidden_method(:tap))
  reveal(:respond_to?)

How would you port that to BasicObject? It has no tap or class or respond_to? method,

[14] pry(main)> BasicObject.instance_methods
=> [:==, :equal?, :!, :!=, :instance_eval, :instance_exec, :__send__, :__id__]

from jbuilder.

SamSaffron avatar SamSaffron commented on June 8, 2024

ok,

 def __class__
    (class << self; self; end).superclass
  end

  def _tap
    yield self
    self
  end

seems ok, does anyone know why :respond_to is revealed?

from jbuilder.

SamSaffron avatar SamSaffron commented on June 8, 2024

Getting jbuilder to work with BlankObject is not trivial, I am half an hour in and still no luck

from jbuilder.

SamSaffron avatar SamSaffron commented on June 8, 2024

and another question ... where is the source for blankslate now, github seems out of date.

from jbuilder.

jjaffeux avatar jjaffeux commented on June 8, 2024

@SErepo you can now close it

from jbuilder.

srpouyet avatar srpouyet commented on June 8, 2024

@SamSaffron & @rolftimmermans thanks for your work good sirs!

cheers

from jbuilder.

axelson avatar axelson commented on June 8, 2024

What version do we need to revert to to avoid the object_id warning?

from jbuilder.

jjaffeux avatar jjaffeux commented on June 8, 2024

gemfile :

gem "jbuilder", :git => 'git://github.com/rails/jbuilder.git', :branch => 'master'

then :

bundle update

from jbuilder.

dhh avatar dhh commented on June 8, 2024

I pushed a new gem, so bundle update will take care of it.

On Sep 21, 2012, at 1:49 PM, Jason Axelson wrote:

What version do we need to revert to to avoid the object_id warning?


Reply to this email directly or view it on GitHub.

David Heinemeier Hansson

from jbuilder.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.