1. Documenting functions that rely on namespace?

Ok, maybe they do not rely upon, but are easier understood by namespace. Here's
what I am speaking of...

include datetime.e as d
include map.e as m

datetime d1
map m1

d1 = d:new(2008, 10, 20, 12, 30, 0)
m1 = m:new()


So, we have 2 new functions. How do I go about documenting that?

--
Jeremy Cowgar
http://jeremy.cowgar.com

new topic     » topic index » view message » categorize

2. Re: Documenting functions that rely on namespace?

Jeremy Cowgar wrote:
> 
> Ok, maybe they do not rely upon, but are easier understood by namespace.
> Here's
> what I am speaking of...
> 
> }}}
<eucode>
> include datetime.e as d
> include map.e as m
> 
> datetime d1
> map m1
> 
> d1 = d:new(2008, 10, 20, 12, 30, 0)
> m1 = m:new()
> </eucode>
{{{

> 
> So, we have 2 new functions. How do I go about documenting that?
> 
> --

Jeremy:

  How did datetime all of a sudden become a type ??

  I think you are going to push or force Euphoria away from being

  a simple easy to learn and use language.

  This is what draws users to Euphoria not a lot exotic features.   

  We don't need another Python or APL language.

  The basic concept of Euphoria will be lost.

  There are NO strings in Euphoria only sequences, objects, integers and

  user define types.

  Any of your so called string operations can be done easily with

  sequence manipulation.


 
Bernie

My files in archive:
WMOTOR, XMOTOR, W32ENGIN, MIXEDLIB, EU_ENGIN, WIN32ERU, WIN32API 

Can be downloaded here:
http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan

new topic     » goto parent     » topic index » view message » categorize

3. Re: Documenting functions that rely on namespace?

Bernie Ryan wrote:
> 
> Jeremy Cowgar wrote:
> > 
> > Ok, maybe they do not rely upon, but are easier understood by namespace.
> > Here's
> > what I am speaking of...
> > 
> > }}}
<eucode>
> > include datetime.e as d
> > include map.e as m
> > 
> > datetime d1
> > map m1
> > 
> > d1 = d:new(2008, 10, 20, 12, 30, 0)
> > m1 = m:new()
> > </eucode>
{{{

> > 
> > So, we have 2 new functions. How do I go about documenting that?
> > 
> > --
> 
> Jeremy:
> 
>   How did datetime all of a sudden become a type ??
> 
>   I think you are going to push or force Euphoria away from being
> 
>   a simple easy to learn and use language.
> 
>   This is what draws users to Euphoria not a lot exotic features.   
> 
>   We don't need another Python or APL language.
> 
>   The basic concept of Euphoria will be lost.
> 
>   There are NO strings in Euphoria only sequences, objects, integers and
> 
>   user define types.
> 
>   Any of your so called string operations can be done easily with
> 
>   sequence manipulation.
> 
> 
> Bernie
> 
> My files in archive:
> WMOTOR, XMOTOR, W32ENGIN, MIXEDLIB, EU_ENGIN, WIN32ERU, WIN32API 
> 
> Can be downloaded here:
> <a
> href="http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan">http://www.rapideuphoria.com/cgi-bin/asearch.exu?dos=on&win=on&lnx=on&gen=on&keywords=bernie+ryan</a>

It would be his user-defined-type for his standard library project, not a
built-in type.

--
A complex system that works is invariably found to have evolved from a simple
system that works.
--John Gall's 15th law of Systemantics.

"Premature optimization is the root of all evil in programming."
--C.A.R. Hoare

j.

new topic     » goto parent     » topic index » view message » categorize

4. Re: Documenting functions that rely on namespace?

Bernie Ryan wrote:
> 
>   How did datetime all of a sudden become a type ??

That is in a standard library that you don't have to use, but you can if you
want the best, fastest code available for that type of data processing.

new topic     » goto parent     » topic index » view message » categorize

5. Re: Documenting functions that rely on namespace?

Bernie Ryan wrote:
> 
>   How did datetime all of a sudden become a type ??

We all decided that datetime in The Archive was a fantastic library and that it
should be included. datetime in the archive has a datetime type. It didn't all of
a sudden become a type, it always was from the beginning.

Now, what is a type? It's nothing more really than a way of telling the compiler
to ensure that a given sequence, atom, integer fits a certain criteria. It's
nothing more.

You can easily do this:

include datetime.e as d
sequence dt1
dt = d:now()


The type datetime just ensures that the sequence meets the date time
requirements, that is 8 integers in a sequence.

What is wrong with type checking?

>   I think you are going to push or force Euphoria away from being
>   a simple easy to learn and use language.

Huh?
 
>   This is what draws users to Euphoria not a lot exotic features.   
>   We don't need another Python or APL language.
>   The basic concept of Euphoria will be lost.

Nobody wants a python. If we wanted python, we would just use it. What people
want is a consistent, complete well thought out set of functions that they use
over and over and over again.

How is making Euphoria easier yet to use bad? Answer that please.

>   There are NO strings in Euphoria only sequences, objects, integers and
>   user define types.
> 
>   Any of your so called string operations can be done easily with
>   sequence manipulation.

Hm. I did not create any string functions. I have added many sequence functions.
Are you refering to trim? pad? Those are all sequence functions. They would just
as well on complex nested sequences as a sequence of ASCII values.

Easily done? No one has shown me yet. Can you show me how to easily trim a set
of atoms/sequences from the end of a sequence?

Yes, Euphoria has no string type, but does anyone here ever read a line of text
from a user or a file and treat it as a string? Of course! To say that functions
that would make it easier to manipulate sequences acting as strings is not
necessary because Euphoria has no strings is crazy.

All of the functions I, and others, have added are all optional includes. No one
is ever required to use them. If you want to still do things the hard way, you
can do it that way. It's your choice. But, for those that want to actually
program their program instead of writing countless support functions so that they
one day can start on their program, they can do that too. Their choice.

Please tell me how having a trim function kills Euphoria? Or having a function
to add two dates together that has been well tested, benchmarked for speed and
accuracy is bad.

The decision has been made to expand Euphoria. Discussion about which functions
and how is still open, but I am getting tired of answering the same question over
and over and over again posed in a different form.

Please, if you have legitimate questions or input, give it. Other wise, let me
and others be in order to work on Euphoria.

--
Jeremy Cowgar
http://jeremy.cowgar.com

new topic     » goto parent     » topic index » view message » categorize

6. Re: Documenting functions that rely on namespace?

Jeremy Cowgar wrote:
> 
> Ok, maybe they do not rely upon, but are easier understood by namespace.
> Here's
> what I am speaking of...
> 
> }}}
<eucode>
> include datetime.e as d
> include map.e as m
> 
> datetime d1
> map m1
> 
> d1 = d:new(2008, 10, 20, 12, 30, 0)
> m1 = m:new()
> </eucode>
{{{

> 
> So, we have 2 new functions. How do I go about documenting that?

EU has a fairly well defined method of documentation at the moment.  There are
essentially two distinct placements.  The first is the documentation that can be
found at http://www.rapideuphoria.com/refman.htm.

Part I is the Core Language
Part II are the built in Library routines
(http://www.rapideuphoria.com/library.htm)

Other libraries have their own documentation in a specific format that I assume
you are familiar with.  See win32Lib for example.

Why wouldn't the standard library not just be documented as win32Lib is?

Mike

new topic     » goto parent     » topic index » view message » categorize

7. Re: Documenting functions that rely on namespace?

Bernie Ryan wrote:
> 
> 
>   How did datetime all of a sudden become a type ??
>   I think you are going to push or force Euphoria away from being
>   a simple easy to learn and use language.
>   This is what draws users to Euphoria not a lot exotic features.   
>   We don't need another Python or APL language.
>   The basic concept of Euphoria will be lost.
>   There are NO strings in Euphoria only sequences, objects, integers and
>   user define types.
> 
>   Any of your so called string operations can be done easily with
>   sequence manipulation.

Yes, and datetime is a UDT.  The standard library has tons of these.

Matt
[line spacing altered to protect the reader]

new topic     » goto parent     » topic index » view message » categorize

8. Re: Documenting functions that rely on namespace?

Mike777 wrote:
> 
> EU has a fairly well defined method of documentation at the moment.  There are
> essentially two
> distinct placements.  The first is the documentation that can be found at <a
> href="http://www.rapideuphoria.com/refman.htm">http://www.rapideuphoria.com/refman.htm</a>.
>  
> 
> Part I is the Core Language
> Part II are the built in Library routines (<a
> href="http://www.rapideuphoria.com/library.htm">http://www.rapideuphoria.com/library.htm</a>)
> 
> Other libraries have their own documentation in a specific format that I
> assume
> you are familiar with.  See win32Lib for example.
>

Yes, that is what I am speaking of. I have added much documentation there
already. The problem is that if we use namespaces, we now have multiple functions
by the exact same name, so far in this instance, new. So, listed in the
Alphabetical listing would be 2 new() functions. Then internally when you use
anchors for navigation, which "new" is one referring to? That's the problem. Not
to mention, just looking pretty confusing with two new() functions listed back to
back.

--
Jeremy Cowgar
http://jeremy.cowgar.com

new topic     » goto parent     » topic index » view message » categorize

9. Re: Documenting functions that rely on namespace?

Jeremy Cowgar wrote:
> 
> Mike777 wrote:
> > 
> > EU has a fairly well defined method of documentation at the moment.  There
> > are
> essentially two</font></i>
> > distinct placements.  The first is the documentation that can be
> found at <a
> href="http://www.rapideuphoria.com/refman.htm">http://www.rapideuphoria.com/refman.htm</a>.</font></i>
> >  
> > 
> > Part I is the Core Language
> > Part II are the built in Library routines (<a
> > href="http://www.rapideuphoria.com/library.htm">http://www.rapideuphoria.com/library.htm</a>)
> > 
> > Other libraries have their own documentation in a specific format that I
> > assume
> > you are familiar with.  See win32Lib for example.
> >
> 
> Yes, that is what I am speaking of. I have added much documentation there
> already.
> The problem is that if we use namespaces, we now have multiple functions by
> the exact same name, so far in this instance, new. So, listed in the
> Alphabetical
> listing would be 2 new() functions. Then internally when you use anchors for
> navigation, which "new" is one referring to? That's the problem. Not to
> mention,
> just looking pretty confusing with two new() functions listed back to back.
> 
> --
> Jeremy Cowgar
> <a href="http://jeremy.cowgar.com">http://jeremy.cowgar.com</a>

For functions and procedures that actually act like object methods on a data
type, list them as if they were methods. So "datetime" would have an entry
describing its fields and methods.

Under the alphabetical entry for "new" put "see datetime" etc. Of course, that
could get kind of unwieldy.

Maybe "datetime:new"?

--
A complex system that works is invariably found to have evolved from a simple
system that works.
--John Gall's 15th law of Systemantics.

"Premature optimization is the root of all evil in programming."
--C.A.R. Hoare

j.

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu