edbrowse-dev - development list for edbrowse
 help / color / mirror / Atom feed
From: Adam Thompson <arthompson1990@gmail.com>
To: Karl Dahlke <eklhad@comcast.net>
Cc: Edbrowse-dev@lists.the-brannons.com
Subject: Re: [Edbrowse-dev] switch compartment
Date: Wed, 12 Feb 2014 10:59:19 +0000	[thread overview]
Message-ID: <20140212105919.GT11542@toaster.adamthompson.me.uk> (raw)
In-Reply-To: <20140112052151.eklhad@comcast.net>

On Wed, Feb 12, 2014 at 05:21:51AM -0500, Karl Dahlke wrote:
> My latest push adds SWITCH_COMPARTMENT to js.h, as suggested by Adam,
> and uses that macro in the establish... and set... functions in jsloc.cpp.
> These are gateway functions from html into the javascript world.
> I also unrooted a couple more parameters that were rooted
> earlier when html did not understand these objects.
> This should not change any behavior, it is just a step along the way.

Ok, pulled and now testing. Thanks for correcting my macro definition to
correctly handle void as well.

> Other functions need to use this macro,
> and still other functions don't really need to set compartment
> because they are internal.

Yeah, sounds like a way ahead.

> Then we can write some error legs that close down javascript for this session
> upon error, but still let edbrowse continue.

Yeah, I guess we'll need some wrappers to do this.
Something like we've done for switching compartments i.e.
if the operation (new object, new value) fails,
print an error and return failure imediately.
I can have a look at implementing these if you want.


On this subject, what c++ standard do we want to try and conform to?
I only ask as I'm wondering if we can just use variadic macros to do this.
I'm not sure how readable this would be but it could certainly speed up the
process whilst not being that unmaintainable in my opinion.

Cheers,
Adam.

  reply	other threads:[~2014-02-12 11:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-12 10:21 Karl Dahlke
2014-02-12 10:59 ` Adam Thompson [this message]
2014-02-12 14:51 Karl Dahlke

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140212105919.GT11542@toaster.adamthompson.me.uk \
    --to=arthompson1990@gmail.com \
    --cc=Edbrowse-dev@lists.the-brannons.com \
    --cc=eklhad@comcast.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).