[GRLUG] Rosetta Code Question [Was: Deserializing JSON in .NET (C#)]
Michael Mol
mikemol at gmail.com
Wed Aug 25 10:28:13 EDT 2010
On Wed, Aug 25, 2010 at 10:14 AM, Adam Tauno Williams
<awilliam at whitemice.org> wrote:
> On Wed, 2010-08-25 at 09:20 -0400, Michael Mol wrote:
>> On Wed, Aug 25, 2010 at 5:58 AM, Adam Tauno Williams
>> <awilliam at whitemice.org> wrote:
>> > On Tue, 2010-08-24 at 22:41 -0400, Dave Brondsema wrote:
>> >> I bet you'd look on rosetta code if there were a page for it ;) I
>> >> started http://rosettacode.org/wiki/JSON
>> >> Mike, btw, I'd suggest removing JSON as a language altogether.
>> > If I implement a solution *using an assembly* does that count as a
>> > solution? I see the "import json" example for Python, while on the
>> > other hand the json_decode is more or less built into PHP. So if I
>> > write a decoder in C# using "using Hyena.JSON" does that could as a "C#
>> > solution"?
>> Yes. The usual way that would work would be:
>> (start example)
>> =={{header|C sharp|C#}}==
>> {{libheader|Hyena}}
>> <lang csharp>// C# code</lang>
>> (/end example)
>> Template:libheader identifies the library which was used. (There's no
>> specific rule about non-public libraries, but I would strongly
>> discourage it)
>
> Ok, cool.
The general gist of it is:
* If it's idiomatic for a language to do something using a library,
then great; whatever's appropriate.
* If it's de facto that code in a langauge uses a library, then fine;
whatever's appropriate.
As an extreme example, I wouldn't force someone writing in x86
assembly to write their own XML parser in-language if they can (and
would prefer) call into a C library for it. There are pure-Perl XML
parsers, but there are also bindings into libxml; each has its place,
and each is a perfectly valid way of accessing XML documents from
within Perl.
As far as site organization, I tend to think in abstractions and
analogous situations, so for whatever other orientation of tools we
come across, the same policy would almost certainly apply.
--
:wq
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
More information about the grlug
mailing list