Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.programming > #3158 > unrolled thread
| Started by | Victor Porton <porton@narod.ru> |
|---|---|
| First post | 2013-03-12 16:47 +0200 |
| Last post | 2013-03-16 06:03 -0700 |
| Articles | 4 — 4 participants |
Back to article view | Back to comp.programming
Which function names to choose? Victor Porton <porton@narod.ru> - 2013-03-12 16:47 +0200
Re: Which function names to choose? bob <bob@coolfone.comze.com> - 2013-03-12 12:22 -0700
Re: Which function names to choose? Jacob Sparre Andersen <sparre@nbi.dk> - 2013-03-13 06:19 +0100
Re: Which function names to choose? malcolm.mclean5@btinternet.com - 2013-03-16 06:03 -0700
| From | Victor Porton <porton@narod.ru> |
|---|---|
| Date | 2013-03-12 16:47 +0200 |
| Subject | Which function names to choose? |
| Message-ID | <khnf5u$66i$1@speranza.aioe.org> |
I am going to create two functions: 1. Append to the list of items (actually the list of children of a HTML DOM node) with an item initialized with a default value. 2. Append to the list of items (actually the list of children of a HTML DOM node) with an item initialized with specified values. What are the best names for functions 1 and 2? I think "add"<->"append" not sure which of these is 1 and which is 2. -- Victor Porton - http://portonvictor.org
[toc] | [next] | [standalone]
| From | bob <bob@coolfone.comze.com> |
|---|---|
| Date | 2013-03-12 12:22 -0700 |
| Message-ID | <37bd7e7e-679b-4801-9a50-0ec2d27adb1c@googlegroups.com> |
| In reply to | #3158 |
On Tuesday, March 12, 2013 9:47:29 AM UTC-5, Victor Porton wrote: > I am going to create two functions: > > > > 1. Append to the list of items (actually the list of children of a HTML DOM > > node) with an item initialized with a default value. > > > > 2. Append to the list of items (actually the list of children of a HTML DOM > > node) with an item initialized with specified values. > > > > What are the best names for functions 1 and 2? > > > > I think "add"<->"append" not sure which of these is 1 and which is 2. > > > > -- > > Victor Porton - http://portonvictor.org I would call them both add and use overloading.
[toc] | [prev] | [next] | [standalone]
| From | Jacob Sparre Andersen <sparre@nbi.dk> |
|---|---|
| Date | 2013-03-13 06:19 +0100 |
| Message-ID | <871ubjri4n.fsf@adaheads.sparre-andersen.dk> |
| In reply to | #3160 |
bob wrote: > Victor Porton wrote: >> I am going to create two functions: >> >> [...] >> What are the best names for functions 1 and 2? > I would call them both add and use overloading. I would call them both Append and use overloading. - If you describe them as "Append ...", that is most likely the name you will understand the next time you look at the code. Greetings, Jacob -- "Problems worthy of attack prove their worth by hitting back" -- Piet Hein
[toc] | [prev] | [next] | [standalone]
| From | malcolm.mclean5@btinternet.com |
|---|---|
| Date | 2013-03-16 06:03 -0700 |
| Message-ID | <54c07db5-e1ba-4f5b-9d9f-eb684a4a5b16@googlegroups.com> |
| In reply to | #3158 |
On Tuesday, March 12, 2013 2:47:29 PM UTC, Victor Porton wrote: > I am going to create two functions: > > 1. Append to the list of items (actually the list of children of a HTML DOM > node) with an item initialized with a default value. > > > 2. A0ppend to the list of items (actually the list of children of a HTML DOM > node) with an item initialized with specified values. > > node_append_child_blank(); /* or "empty" or "null" depending on exactly what a default is " node_append_child( DOM_NODE *child);
[toc] | [prev] | [standalone]
Back to top | Article view | comp.programming
csiph-web