emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [GSoC] Org Merge Driver Update
@ 2012-08-13 23:15 Andrew Young
  2012-08-15 17:04 ` Eric Schulte
  2012-08-18  2:09 ` Simon Thum
  0 siblings, 2 replies; 9+ messages in thread
From: Andrew Young @ 2012-08-13 23:15 UTC (permalink / raw)
  To: emacs-orgmode

Hello Everyone,

I've been working on a merge driver for org-mode documents over the
summer as a Google Summer of Code project. I just wanted to show
everyone some progress on the merge driver.

There are some new examples you can see at the project page [1][2], and
instructions on how to build and use it.

the source is available here: git clone git://orgmode.org/org-merge-driver.git

I'd really appreciate if anyone could take the merge driver out for a
test spin, and come back with any kind of feedback, such as:

- file output
- customization
- the user interface
- the merging rules
- new features and element specific support
- testing
- neat ideas, etc.

There is only about a week left in GSoC, but I'm planning to continue to
develop the merge driver past the end of GSoC.

Please take a look, and thanks,

Andrew Young

[1] project page:
http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/
[2] examples:
http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/examples.html

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-13 23:15 [GSoC] Org Merge Driver Update Andrew Young
@ 2012-08-15 17:04 ` Eric Schulte
  2012-08-15 19:22   ` Bastien
                     ` (2 more replies)
  2012-08-18  2:09 ` Simon Thum
  1 sibling, 3 replies; 9+ messages in thread
From: Eric Schulte @ 2012-08-15 17:04 UTC (permalink / raw)
  To: Andrew Young; +Cc: emacs-orgmode

Andrew Young <youngar17@gmail.com> writes:

> Hello Everyone,
>
> I've been working on a merge driver for org-mode documents over the
> summer as a Google Summer of Code project. I just wanted to show
> everyone some progress on the merge driver.
>
> There are some new examples you can see at the project page [1][2], and
> instructions on how to build and use it.
>
> the source is available here: git clone git://orgmode.org/org-merge-driver.git
>
> I'd really appreciate if anyone could take the merge driver out for a
> test spin, and come back with any kind of feedback, such as:
>
> - file output
> - customization
> - the user interface
> - the merging rules
> - new features and element specific support
> - testing
> - neat ideas, etc.
>
> There is only about a week left in GSoC, but I'm planning to continue to
> develop the merge driver past the end of GSoC.
>
> Please take a look, and thanks,
>
> Andrew Young
>
> [1] project page:
> http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/
> [2] examples:
> http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/examples.html
>

I'm very excited to start using this merge driver.  I've put together an
Arch Linux User Repository (aur) package, which can be used by Arch
Linux users to install the org-merge-driver with pacman.  It is
available at [1], if others find it useful and if Andrew doesn't object
I'd be happy to push it into the official aur database.  It is very
simple and installs directly from git.

I spent some time testing this locally and I've run into what appears to
be an error.  Namely when merging a tree with multiple new sub-headings
the merge completes successfully, but the subheadings from the OTHER
branch are deleted by the merge.  Here [2] is a tarball of the entire
git directory after the failed merge.  Please let me know if there is
any other debug information I can provide.

Thanks,

Footnotes: 
[1]  http://cs.unm.edu/~eschulte/data/org-merge-driver-20120815-1.src.tar.gz

[2]  http://cs.unm.edu/~eschulte/data/fruit-test.tar.bz2

-- 
Eric Schulte
http://cs.unm.edu/~eschulte

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-15 17:04 ` Eric Schulte
@ 2012-08-15 19:22   ` Bastien
  2012-08-15 20:15   ` Rasmus
  2012-08-16 10:27   ` Andrew Young
  2 siblings, 0 replies; 9+ messages in thread
From: Bastien @ 2012-08-15 19:22 UTC (permalink / raw)
  To: Eric Schulte; +Cc: Andrew Young, emacs-orgmode

Eric Schulte <eric.schulte@gmx.com> writes:

> I'm very excited to start using this merge driver.  I've put together an
> Arch Linux User Repository (aur) package, which can be used by Arch
> Linux users to install the org-merge-driver with pacman.  It is
> available at [1], if others find it useful and if Andrew doesn't object
> I'd be happy to push it into the official aur database.  It is very
> simple and installs directly from git.

Hey!  That's nice -- ArchLinux user here.  I installed the package
correctly.  +1 for adding it to AUR.

Thanks!

-- 
 Bastien

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-15 17:04 ` Eric Schulte
  2012-08-15 19:22   ` Bastien
@ 2012-08-15 20:15   ` Rasmus
  2012-08-16 10:27   ` Andrew Young
  2 siblings, 0 replies; 9+ messages in thread
From: Rasmus @ 2012-08-15 20:15 UTC (permalink / raw)
  To: emacs-orgmode

Eric Schulte <eric.schulte@gmx.com> writes:

> I'm very excited to start using this merge driver.  I've put together an
> Arch Linux User Repository (aur) package, which can be used by Arch
> Linux users to install the org-merge-driver with pacman.  It is
> available at [1], if others find it useful and if Andrew doesn't object
> I'd be happy to push it into the official aur database.  It is very
> simple and installs directly from git.

you should add gnulib, it would seem (as a makedepends?).  At least
gnulib-tool isn't on my system. 

makedepends=('git' 'autoconf' 'gnulib')

Also, installing local is kind of non-default (IMO). . . 

$ pacman -Ql org-merge-driver 
  org-merge-driver /usr/
  org-merge-driver /usr/local/
  org-merge-driver /usr/local/bin/
  org-merge-driver /usr/local/bin/org-merge-driver
  org-merge-driver /usr/local/share/
  org-merge-driver /usr/local/share/doc/
  org-merge-driver /usr/local/share/doc/org-merge-driver/
  org-merge-driver /usr/local/share/doc/org-merge-driver/README

Thus, conditional on my taste I'd build like:

  ## Build
  msg "Building..."
  cd $_gitname
  gnulib-tool --add-import
  autoreconf -i
  ./configure --prefix=/usr ## added prefix
  make

It's also encouraged to use -git in the name, but I don't always
follow it. . .

I have a couple of local org `addons' that I never managed to push to
the AUR, but I encourage you to push the merge drive.

BTW: I would have never seen that I can use this for my hg had you not
published the package here!

–Rasmus

-- 
Don't panic!!!

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-15 17:04 ` Eric Schulte
  2012-08-15 19:22   ` Bastien
  2012-08-15 20:15   ` Rasmus
@ 2012-08-16 10:27   ` Andrew Young
  2012-08-16 14:34     ` Eric Schulte
  2 siblings, 1 reply; 9+ messages in thread
From: Andrew Young @ 2012-08-16 10:27 UTC (permalink / raw)
  To: Eric Schulte; +Cc: emacs-orgmode

Hi,
On Wed, Aug 15, 2012 at 1:04 PM, Eric Schulte <eric.schulte@gmx.com> wrote:
> I'm very excited to start using this merge driver.  I've put together an
> Arch Linux User Repository (aur) package, which can be used by Arch
> Linux users to install the org-merge-driver with pacman.  It is
> available at [1],

Thank you so much for doing this! I'm also an Arch Linux user, and am
now using your package as well!

> if others find it useful and if Andrew doesn't object
> I'd be happy to push it into the official aur database.  It is very
> simple and installs directly from git.
>

Yes, of course I don't mind.  This would be _awesome_.

I just installed OMD through your package. Pretty exciting for
me! It took me a little bit to realize the linked file was not
corrupted ;), but HTML to the new package.

Regarding the gnulib dependency:

I have included the Gnulib sources which my project depends on
directly into the git repository. Because of this, gnulib shouldn't be
nessecary to build. I've done this for two main reasons:

1. I thought that would make the dependencies easier on everyone else
   to build and install.

2. I believe I've uncovered a bug in one of the sources I'm using, and
   so for the time being I'm using a slightly edited version.

I'm really not sure what the standard is for using GnuLib in a
project. I think that distributing Gnulib dependencies directly with a
project may be typical, given that it is used at the source level. (If
anyone has any opinion on this, please share)

For the time being, it may be best to leave Gnulib out as dependency,
until I find out what to do. Re-importing Gnulib modules may
reintroduce the problem I was having.

> I spent some time testing this locally and I've run into what appears to
> be an error.  Namely when merging a tree with multiple new sub-headings
> the merge completes successfully, but the subheadings from the OTHER
> branch are deleted by the merge.  Here [2] is a tarball of the entire
> git directory after the failed merge.  Please let me know if there is
> any other debug information I can provide.
>

Thank you for letting me know, and your detailed example.  This should
be fixed now, along with some other issues.

> Thanks,
>
> Footnotes:
> [1]  http://cs.unm.edu/~eschulte/data/org-merge-driver-20120815-1.src.tar.gz
>
> [2]  http://cs.unm.edu/~eschulte/data/fruit-test.tar.bz2
>
> --
> Eric Schulte
> http://cs.unm.edu/~eschulte

Thanks again for doing all this, it's really appreciated!

Sincerely,
Andrew Young

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-16 10:27   ` Andrew Young
@ 2012-08-16 14:34     ` Eric Schulte
  0 siblings, 0 replies; 9+ messages in thread
From: Eric Schulte @ 2012-08-16 14:34 UTC (permalink / raw)
  To: Andrew Young; +Cc: emacs-orgmode

Andrew Young <youngar17@gmail.com> writes:

> Hi,
> On Wed, Aug 15, 2012 at 1:04 PM, Eric Schulte <eric.schulte@gmx.com> wrote:
>> I'm very excited to start using this merge driver.  I've put together an
>> Arch Linux User Repository (aur) package, which can be used by Arch
>> Linux users to install the org-merge-driver with pacman.  It is
>> available at [1],
>
> Thank you so much for doing this! I'm also an Arch Linux user, and am
> now using your package as well!
>
>> if others find it useful and if Andrew doesn't object
>> I'd be happy to push it into the official aur database.  It is very
>> simple and installs directly from git.
>>
>
> Yes, of course I don't mind.  This would be _awesome_.
>
> I just installed OMD through your package. Pretty exciting for
> me! It took me a little bit to realize the linked file was not
> corrupted ;), but HTML to the new package.
>
> Regarding the gnulib dependency:
>
> I have included the Gnulib sources which my project depends on
> directly into the git repository. Because of this, gnulib shouldn't be
> nessecary to build. I've done this for two main reasons:
>
> 1. I thought that would make the dependencies easier on everyone else
>    to build and install.
>
> 2. I believe I've uncovered a bug in one of the sources I'm using, and
>    so for the time being I'm using a slightly edited version.
>
> I'm really not sure what the standard is for using GnuLib in a
> project. I think that distributing Gnulib dependencies directly with a
> project may be typical, given that it is used at the source level. (If
> anyone has any opinion on this, please share)
>

I don't know about this personally, but from the gnulib site [1], this
sounds like the intended method of use.

>
> For the time being, it may be best to leave Gnulib out as dependency,
> until I find out what to do. Re-importing Gnulib modules may
> reintroduce the problem I was having.
>

I'll remove 'gnulib' from the dependencies and remove the libtool
portion of the build sequence.

>
>> I spent some time testing this locally and I've run into what appears to
>> be an error.  Namely when merging a tree with multiple new sub-headings
>> the merge completes successfully, but the subheadings from the OTHER
>> branch are deleted by the merge.  Here [2] is a tarball of the entire
>> git directory after the failed merge.  Please let me know if there is
>> any other debug information I can provide.
>>
>
> Thank you for letting me know, and your detailed example.  This should
> be fixed now, along with some other issues.
>

Yes, I can confirm that this now works for me.

>
>> Thanks,
>>
>> Footnotes:
>> [1]  http://cs.unm.edu/~eschulte/data/org-merge-driver-20120815-1.src.tar.gz
>>
>> [2]  http://cs.unm.edu/~eschulte/data/fruit-test.tar.bz2
>>
>> --
>> Eric Schulte
>> http://cs.unm.edu/~eschulte
>
> Thanks again for doing all this, it's really appreciated!
>

My pleasure, I've now submitted this package to the AUR database [2].

Cheers,

>
> Sincerely,
> Andrew Young
>


Footnotes: 
[1]  http://www.gnu.org/software/gnulib/ (end of third paragraph)

[2]  https://aur.archlinux.org/packages.php?ID=62052

-- 
Eric Schulte
http://cs.unm.edu/~eschulte

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-13 23:15 [GSoC] Org Merge Driver Update Andrew Young
  2012-08-15 17:04 ` Eric Schulte
@ 2012-08-18  2:09 ` Simon Thum
  2012-08-18  8:24   ` Andrew Young
  1 sibling, 1 reply; 9+ messages in thread
From: Simon Thum @ 2012-08-18  2:09 UTC (permalink / raw)
  To: Andrew Young; +Cc: emacs-orgmode

Hi Andrew,

sorry to report less exciting things. I could not compile - the repo 
contains two invalid links into my system:

lrwxrwxrwx 1 simon users    38 Aug 18 04:01 tap-driver.sh -> 
/usr/share/automake-1.12/tap-driver.sh
lrwxrwxrwx 1 simon users    36 Aug 18 04:01 test-driver -> 
/usr/share/automake-1.12/test-driver

I'm on gentoo and do not have automake 1.12. Using a link not the right 
thing IMO.

II removed those from being referenced in source files and came farther, 
only for gcc to balk on

doc_ref.h:54:3: error: redefinition of typedef ‘doc_ref’
doc_ref.h:31:24: note: previous declaration of ‘doc_ref’ was here
doc_ref.h: In function ‘doc_ref_check_for_circular_conflict’:

and other such occurrences.

I'm not sure about the cause, but maybe typedefs conflict with struct names?

HTH,

Simon

On 08/14/2012 01:15 AM, Andrew Young wrote:
> Hello Everyone,
>
> I've been working on a merge driver for org-mode documents over the
> summer as a Google Summer of Code project. I just wanted to show
> everyone some progress on the merge driver.
>
> There are some new examples you can see at the project page [1][2], and
> instructions on how to build and use it.
>
> the source is available here: git clone git://orgmode.org/org-merge-driver.git
>
> I'd really appreciate if anyone could take the merge driver out for a
> test spin, and come back with any kind of feedback, such as:
>
> - file output
> - customization
> - the user interface
> - the merging rules
> - new features and element specific support
> - testing
> - neat ideas, etc.
>
> There is only about a week left in GSoC, but I'm planning to continue to
> develop the merge driver past the end of GSoC.
>
> Please take a look, and thanks,
>
> Andrew Young
>
> [1] project page:
> http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/
> [2] examples:
> http://orgmode.org/worg/org-contrib/gsoc2012/student-projects/git-merge-tool/examples.html
>
>

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-18  2:09 ` Simon Thum
@ 2012-08-18  8:24   ` Andrew Young
  2012-08-26  0:23     ` Simon Thum
  0 siblings, 1 reply; 9+ messages in thread
From: Andrew Young @ 2012-08-18  8:24 UTC (permalink / raw)
  To: Simon Thum; +Cc: emacs-orgmode

Hello Simon,

On Fri, Aug 17, 2012 at 10:09 PM, Simon Thum <simon.thum@gmx.de> wrote:
> Hi Andrew,
>
> sorry to report less exciting things. I could not compile - the repo
> contains two invalid links into my system:
>
> lrwxrwxrwx 1 simon users    38 Aug 18 04:01 tap-driver.sh ->
> /usr/share/automake-1.12/tap-driver.sh
> lrwxrwxrwx 1 simon users    36 Aug 18 04:01 test-driver ->
> /usr/share/automake-1.12/test-driver
>
> I'm on gentoo and do not have automake 1.12. Using a link not the right
> thing IMO.
>

I believe I've fixed the issue, I hadn't realized they were links.
They should be updated with the actual files now. Thanks for reporting
it.

> II removed those from being referenced in source files and came farther,
> only for gcc to balk on
>
> doc_ref.h:54:3: error: redefinition of typedef ‘doc_ref’
> doc_ref.h:31:24: note: previous declaration of ‘doc_ref’ was here
> doc_ref.h: In function ‘doc_ref_check_for_circular_conflict’:
>
> and other such occurrences.
>
> I'm not sure about the cause, but maybe typedefs conflict with struct names?
>

It seems that a lot of my typedefs may not be valid c, but are
accepted by newer versions of gcc and some other compilers. I only get
a warning if I enable -pedantic using "gcc version 4.7.1 20120721
(prerelease) (GCC)".

I'm in the process of cleaning up my headers and should have something
for you soon. In the meantime, I believe upgrading gcc should make the
issue disappear. Let me know if I'm completely wrong :-)

> HTH,
>
> Simon

Thanks for trying out the merge driver. it's much appreciated.

Sincerely,
Andrew

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [GSoC] Org Merge Driver Update
  2012-08-18  8:24   ` Andrew Young
@ 2012-08-26  0:23     ` Simon Thum
  0 siblings, 0 replies; 9+ messages in thread
From: Simon Thum @ 2012-08-26  0:23 UTC (permalink / raw)
  To: Andrew Young; +Cc: emacs-orgmode

Hi Andrew,

I finally got to code a bit and tried clang on the merge driver. BTW you 
should probably mention prerequisites like gcc 4.7.

clang suggests your syntax is C11/requires a c++-style ODR. Also there 
is one error and numerous warnings you might want to fix.

HTH,

Simon

clang -DHAVE_CONFIG_H -I. -I..    -O0 -I../gnulib/lib -g -O2 -MT oo 
`test -f 'org_heading.c' || echo './'`org_heading.c
In file included from org_heading.c:34:
In file included from ./doc_elt.h:28:
In file included from ./doc_elt_ops.h:29:
./doc_ref.h:54:3: warning: redefinition of typedef 'doc_ref' is a
} doc_ref;
   ^
./doc_ref.h:31:24: note: previous definition is here 

typedef struct doc_ref doc_ref;
                        ^
./doc_ref.h:203:37: warning: format specifies type 'int' but the 
argument has type 'doc_elt *' (aka 'st
       printf ("checking parent par=%d, ref=%d\n",
                                    ~^
./doc_ref.h:203:45: warning: format specifies type 'int' but the 
argument has type 'doc_elt *' (aka 'st
       printf ("checking parent par=%d, ref=%d\n",
                                            ~^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:28:
./doc_elt_ops.h:32:24: warning: redefinition of typedef 'doc_elt' is a 
C11 feature [-Wtypedef-redefinit
typedef struct doc_elt doc_elt;
                        ^
./doc_ref.h:29:24: note: previous definition is here 

typedef struct doc_elt doc_elt;
                        ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:28:
./doc_elt_ops.h:34:27: warning: redefinition of typedef 'print_ctxt' is 
a C11 feature [-Wtypedef-redefinitio
typedef struct print_ctxt print_ctxt;
                           ^
./print_ctxt.h:69:3: note: previous definition is here 

} print_ctxt;
   ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:28:
./doc_elt_ops.h:38:27: warning: redefinition of typedef 'merge_ctxt' is 
a C11 feature [-Wtypedef-redefinitio
typedef struct merge_ctxt merge_ctxt;
                           ^
./doc_ref.h:30:27: note: previous definition is here 

typedef struct merge_ctxt merge_ctxt;
                           ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:28:
./doc_elt_ops.h:40:24: warning: redefinition of typedef 'doc_ref' is a 
C11 feature [-Wtypedef-redefinit
typedef struct doc_ref doc_ref;
                        ^
./doc_ref.h:54:3: note: previous definition is here 

} doc_ref;
   ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:31:
./merge_ctxt.h:35:31: warning: redefinition of typedef 'gl_list_t' is a 
C11 feature [-Wtypedef-redefinition]
typedef struct gl_list_impl * gl_list_t;
                               ^
../gnulib/lib/gl_list.h:111:31: note: previous definition is here 

typedef struct gl_list_impl * gl_list_t;
                               ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:31:
./merge_ctxt.h:45:3: warning: redefinition of typedef 'merge_ctxt' is a 
C11 feature [-Wtypedef-redefinition]
} merge_ctxt;
   ^
./doc_elt_ops.h:38:27: note: previous definition is here 

typedef struct merge_ctxt merge_ctxt;
                           ^
In file included from org_heading.c:34: 

In file included from ./doc_elt.h:33:
./parse_ctxt.h:30:31: warning: redefinition of typedef 'gl_list_t' is a 
C11 feature [-Wtypedef-redefinition]
typedef struct gl_list_impl * gl_list_t;
                               ^
./merge_ctxt.h:35:31: note: previous definition is here 

typedef struct gl_list_impl * gl_list_t;
                               ^
In file included from org_heading.c:34: 

./doc_elt.h:36:24: warning: redefinition of typedef 'smerger' is a C11 
feature [-Wtypedef-redefinition]
typedef struct smerger smerger;
                        ^
./merge_ctxt.h:38:24: note: previous definition is here 

typedef struct smerger smerger;
                        ^
In file included from org_heading.c:34: 

./doc_elt.h:51:3: warning: redefinition of typedef 'doc_elt' is a
} doc_elt;
   ^
./doc_elt_ops.h:32:24: note: previous definition is here 

typedef struct doc_elt doc_elt;
                        ^
In file included from org_heading.c:34: 

./doc_elt.h:57:3: warning: redefinition of typedef 'doc_key' is a
} doc_key;
   ^
./doc_elt_ops.h:36:24: note: previous definition is here 

typedef struct doc_key doc_key;
                        ^
In file included from org_heading.c:34: 

./doc_elt.h:153:1: warning: control reaches end of non-void functi
}
^
In file included from org_heading.c:36: 

./doc_elt_util.h:85:3: warning: redefinition of typedef 'substr' is a 
C11 feature [-Wtypedef-redefinitio
} substr;
   ^
./doc_elt_util.h:72:23: note: previous definition is here 

typedef struct substr substr;
                       ^
./doc_elt_util.h:109:37: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned
   debug_msg (DOC_ELT, 5, "a.length=%d b.length=%d  ", a.length, b.
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                    %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
In file included from org_heading.c:36: 

./doc_elt_util.h:109:49: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned
   debug_msg (DOC_ELT, 5, "a.length=%d b.length=%d  ", a.length, b.length);
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
                                                %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
In file included from org_heading.c:36: 

./doc_elt_util.h:128:10: warning: implicit declaration of function 
'stncmp' is invalid in C99 [-Wimplicit-funct
   return stncmp (substr.string, str, min_length);
          ^
./doc_elt_util.h:222:1: warning: control reaches end of non-void 
function [-Wreturn-type]
}
^
./doc_elt_util.h:230:1: warning: control reaches end of non-void 
function [-Wreturn-type]
}
^
In file included from org_heading.c:38: 

./org_heading.h:37:28: warning: redefinition of typedef 'doc_elt_ops' is 
a C11 feature [-Wtypedef-redefinition]
typedef struct doc_elt_ops doc_elt_ops;
                            ^
./doc_elt_ops.h:77:3: note: previous definition is here 

} doc_elt_ops;
   ^
In file included from org_heading.c:39: 

./org_text.h:30:25: warning: redefinition of typedef 'org_text' is a C11 
feature [-Wtypedef-redefinition
typedef struct org_text org_text;
                         ^
./org_heading.h:31:25: note: previous definition is here 

typedef struct org_text org_text;
                         ^
In file included from org_heading.c:39: 

./org_text.h:40:28: warning: redefinition of typedef 'doc_elt_ops' is a 
C11 feature [-Wtypedef-redefinition]
typedef struct doc_elt_ops doc_elt_ops;
                            ^
./org_heading.h:37:28: note: previous definition is here 

typedef struct doc_elt_ops doc_elt_ops;
                            ^
org_heading.c:127:3: warning: redefinition of typedef 'org_heading_data' 
is a C11 feature [-Wtypedef-redefinition]
} org_heading_data;
   ^
org_heading.c:44:33: note: previous definition is here 

typedef struct org_heading_data org_heading_data;
                                 ^
org_heading.c:139:3: warning: redefinition of typedef 'org_heading' is a 
C11 feature [-Wtypedef-redefinition]
} org_heading;
   ^
./org_heading.h:35:28: note: previous definition is here 

typedef struct org_heading org_heading;
                            ^
org_heading.c:149:3: warning: redefinition of typedef 'property' is a 
C11 feature [-Wtypedef-redefinition]
} property;
   ^
org_heading.c:79:25: note: previous definition is here 

typedef struct property property;
                         ^
org_heading.c:392:51: warning: format specifies type 'int' but the 
argument has type 'unsigned long' [-Wformat]
           debug_msg (DOC_ELT, 5, "Found first colon, at %d\n", ubound - i -
           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
                                                         %ld 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:394:18: warning: using the result of an assignment as a 
condition without parentheses [-Wparentheses]
           if (foundtags = false)
               ~~~~~~~~~~^~~~~~~
org_heading.c:394:18: note: place parentheses around the assignment to 
silence this warning
           if (foundtags = false)
                         ^
               (                ) 

org_heading.c:394:18: note: use '==' to turn this assignment into an 
equality comparison
           if (foundtags = false)
                         ^
                         == 

org_heading.c:397:55: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned long') [-Wformat]
               debug_msg (DOC_ELT, 5, "Setting  tags_ubound =%d\n", 
tags_ubound);
 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
                                                             %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:404:50: warning: format specifies type 'int' but the 
argument has type 'unsigned long' [-Wformat]
                   debug_msg (DOC_ELT, 5, "Found whitespace at %d, 
tagsfound=%d\n"
 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
                                                               %ld 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:419:46: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned long') [-Wformat]
                              "tags_lbound = %d; tags_ubound = %d\n
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~
                                             %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:419:64: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned long') [-Wformat]
                              "tags_lbound = %d; tags_ubound = %d\n
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~
                                                               %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg' 

     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:426:30: warning: data argument not used by format string 
[-Wformat-extra-args]
                              tags_lbound, tags_ubound);
                              ^~~~~~~~~~~~~~~~~~~~~~~~~
./debug.h:70:46: note: expanded from macro 'debug_msg' 

       level, __FILE__, __LINE__, __func__, ##__VA_ARGS__);      \
                                              ^
org_heading.c:761:50: warning: using the result of an assignment as a 
condition without parentheses [-Wparentheses]
                   if (a_body.string[a_lookahead] = ']')
                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
org_heading.c:761:50: note: place parentheses around the assignment to 
silence this warning
                   if (a_body.string[a_lookahead] = ']')
                                                  ^
                       (                               ) 

org_heading.c:761:50: note: use '==' to turn this assignment into an 
equality comparison
                   if (a_body.string[a_lookahead] = ']')
                                                  ^
                                                  == 

org_heading.c:856:50: warning: using the result of an assignment as a 
condition without parentheses [-Wparentheses]
                   if (b_body.string[b_lookahead] = ']')
                       ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
org_heading.c:856:50: note: place parentheses around the assignment to 
silence this warning
                   if (b_body.string[b_lookahead] = ']')
                                                  ^
                       (                               ) 

org_heading.c:856:50: note: use '==' to turn this assignment into an 
equality comparison
                   if (b_body.string[b_lookahead] = ']')
                                                  ^
                                                  == 

org_heading.c:1535:44: warning: format specifies type 'int' but the 
argument has type 'size_t' (aka 'unsigned long') [-Wformat]
           debug_msg (ORG_HEADING, 5, "cur=%d, rel=%d \n", 
ctxt->current_level, level)
 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                           %zd 

./debug.h:69:48: note: expanded from macro 'debug_msg'
     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^
org_heading.c:1668:70: warning: data argument not used by format string 
[-Wformat-extra-args]
   debug_msg (ORG_HEADING, 5, "level: %d", h->data[index]->rel_level, out);
   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
./debug.h:70:46: note: expanded from macro 'debug_msg'
       level, __FILE__, __LINE__, __func__, ##__VA_ARGS__);      \
                                              ^
org_heading.c:1708:7: warning: implicit declaration of function 
'smerger_register_delete' is invalid in C99 
[-Wimplicit-function-declaration]
       smerger_register_delete (ctxt->global_smerger, ref, ctxt);
       ^
org_heading.c:1735:7: warning: implicit declaration of function 
'smerger_register_insert' is invalid in C99 
[-Wimplicit-function-declaration]
       smerger_register_insert (ctxt->global_smerger, ref, ctxt);
       ^
org_heading.c:1782:3: error: non-void function 'parse_tags' should 
return a value [-Wreturn-type]
   return;
   ^
org_heading.c:1900:43: warning: format specifies type 'int' but the 
argument has type 'unsigned long' [-Wformat]
       debug_msg (DOC_ELT, 5, "Generating %d long body_ws\n",
       ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
                                          %ld
./debug.h:69:48: note: expanded from macro 'debug_msg'
     fprintf (DEBUG_OUT, #module"-%d:%s:%d:%s " format,          \
                                                ^





On 08/18/2012 10:24 AM, Andrew Young wrote:
> It seems that a lot of my typedefs may not be valid c, but are
> accepted by newer versions of gcc and some other compilers. I only get
> a warning if I enable -pedantic using "gcc version 4.7.1 20120721
> (prerelease) (GCC)".
>
> I'm in the process of cleaning up my headers and should have something
> for you soon. In the meantime, I believe upgrading gcc should make the
> issue disappear. Let me know if I'm completely wrong :-)
>
>> HTH,
>>
>> Simon
>
> Thanks for trying out the merge driver. it's much appreciated.
>
> Sincerely,
> Andrew
>
>

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2012-08-26  0:23 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-13 23:15 [GSoC] Org Merge Driver Update Andrew Young
2012-08-15 17:04 ` Eric Schulte
2012-08-15 19:22   ` Bastien
2012-08-15 20:15   ` Rasmus
2012-08-16 10:27   ` Andrew Young
2012-08-16 14:34     ` Eric Schulte
2012-08-18  2:09 ` Simon Thum
2012-08-18  8:24   ` Andrew Young
2012-08-26  0:23     ` Simon Thum

Code repositories for project(s) associated with this inbox:

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).