{"action":"created","issue":{"url":"https://api.github.com/repos/robotology/yarp/issues/1602","repository_url":"https://api.github.com/repos/robotology/yarp","labels_url":"https://api.github.com/repos/robotology/yarp/issues/1602/labels{/name}","comments_url":"https://api.github.com/repos/robotology/yarp/issues/1602/comments","events_url":"https://api.github.com/repos/robotology/yarp/issues/1602/events","html_url":"https://github.com/robotology/yarp/issues/1602","id":305734140,"number":1602,"title":"Operators should not be in the yarp::math namespace","user":{"login":"drdanz","id":1100056,"avatar_url":"https://avatars2.githubusercontent.com/u/1100056?v=4","gravatar_id":"","url":"https://api.github.com/users/drdanz","html_url":"https://github.com/drdanz","followers_url":"https://api.github.com/users/drdanz/followers","following_url":"https://api.github.com/users/drdanz/following{/other_user}","gists_url":"https://api.github.com/users/drdanz/gists{/gist_id}","starred_url":"https://api.github.com/users/drdanz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drdanz/subscriptions","organizations_url":"https://api.github.com/users/drdanz/orgs","repos_url":"https://api.github.com/users/drdanz/repos","events_url":"https://api.github.com/users/drdanz/events{/privacy}","received_events_url":"https://api.github.com/users/drdanz/received_events","type":"User","site_admin":false},"labels":[{"id":835112594,"url":"https://api.github.com/repos/robotology/yarp/labels/Affects:%20YARP%20v2.3.72","name":"Affects: YARP v2.3.72","color":"006b75","default":false},{"id":90673779,"url":"https://api.github.com/repos/robotology/yarp/labels/Component:%20Library%20-%20YARP_math","name":"Component: Library - YARP_math","color":"207de5","default":false},{"id":772386001,"url":"https://api.github.com/repos/robotology/yarp/labels/Type:%20Breaking%20Change","name":"Type: Breaking Change","color":"5319e7","default":false},{"id":36381544,"url":"https://api.github.com/repos/robotology/yarp/labels/Type:%20Bug","name":"Type: Bug","color":"5319e7","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-03-15T21:59:30Z","updated_at":"2018-03-15T22:32:16Z","closed_at":null,"author_association":"OWNER","body":"`Vector` and `Matrix` operators are defined inside the `yarp::math` namespace.\r\n\r\nhttps://github.com/robotology/yarp/blob/29e9108a52713dbe737d9a9c44a62da3adc3ce51/src/libYARP_math/include/yarp/math/Math.h#L16-L27\r\n\r\nThis means that, in order to perform an operation (for example `Vector b = a + s;`), the user has to add `using namespace yarp::math;` or to call the operator explicitly, i.e. (I think) something like this: `Vector b = yarp::math::operator+(a, s);`\r\nThe first option is considered bad practice, and the second option is just wrong.\r\n\r\nI think we could just move them outside of the namespace, the only effect is if someone is using the second syntax, but I don't think anyone would be doing that..."},"comment":{"url":"https://api.github.com/repos/robotology/yarp/issues/comments/373543956","html_url":"https://github.com/robotology/yarp/issues/1602#issuecomment-373543956","issue_url":"https://api.github.com/repos/robotology/yarp/issues/1602","id":373543956,"user":{"login":"lornat75","id":1403333,"avatar_url":"https://avatars1.githubusercontent.com/u/1403333?v=4","gravatar_id":"","url":"https://api.github.com/users/lornat75","html_url":"https://github.com/lornat75","followers_url":"https://api.github.com/users/lornat75/followers","following_url":"https://api.github.com/users/lornat75/following{/other_user}","gists_url":"https://api.github.com/users/lornat75/gists{/gist_id}","starred_url":"https://api.github.com/users/lornat75/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lornat75/subscriptions","organizations_url":"https://api.github.com/users/lornat75/orgs","repos_url":"https://api.github.com/users/lornat75/repos","events_url":"https://api.github.com/users/lornat75/events{/privacy}","received_events_url":"https://api.github.com/users/lornat75/received_events","type":"User","site_admin":false},"created_at":"2018-03-15T22:32:16Z","updated_at":"2018-03-15T22:32:16Z","author_association":"OWNER","body":"I am ok moving the operators outside yarp::math. I would keep however the current implementation when it relies on linear algebra lib, and keep them on libYARP_math. \r\n\r\n\r\n"}}
{"actor":{"display_login":"lornat75"}}