Bug 115879 - Odd behaviour of concatenated NOT functions
Summary: Odd behaviour of concatenated NOT functions
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Eike Rathke
URL:
Whiteboard: target:6.1.0 target:7.2.0
Keywords:
Depends on:
Blocks:
 
Reported: 2018-02-20 12:57 UTC by Eike Rathke
Modified: 2021-03-05 10:45 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Eike Rathke 2018-02-20 12:57:49 UTC
NOT in some context is treated as a low precedence unary operator instead of a function, for legacy reasons, which is neither documented nor specified, and when concatenated without operator leads to odd behaviour such as
=NOT(0)NOT(0) => TRUE
=NOT(0)NOT(1) => FALSE
=NOT(1)NOT(0) => TRUE
=NOT(1)NOT(1) => FALSE
These expressions should result in error instead.
Comment 1 Commit Notification 2018-02-20 22:25:32 UTC
Eike Rathke committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=a8d4d4b9edca48b8fb94dbb06d7dd1e689b07b98

Resolves: tdf#115879 treat NOT as the 1-parameter function that it is

It will be available in 6.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 2 himajin100000 2018-02-21 02:53:11 UTC
>for legacy reasons
Is the reason also related to Bug 52601?
Comment 3 Eike Rathke 2018-02-21 09:11:50 UTC
No.
Comment 4 Commit Notification 2021-03-05 10:45:45 UTC
Xisco Fauli committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/d6886c340d1c940a4b3ab7e7ca499fff63183845

tdf#115879: sc_logical_functions: Add function test

It will be available in 7.2.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.