bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

escaped newline in macro expansion in command line


From: Humm
Subject: escaped newline in macro expansion in command line
Date: Fri, 24 Dec 2021 10:45:10 +0000

(I’m not subscribed to the list.)

Consider the Makefile:

        .POSIX:
        M = word
        all:
                echo ${M:word=a\
                b}

I believe, as the escaped newline is in a command line, the expected behavior is to let the macro expand to it, and thus to run the command

        echo a\
        b

with output `ab`.  The actual output is `a b`.

Tested with gmake 4.3 (Alpine Linux) (same with bmake).

--
Humm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]