Regarding - error: only virtual member functions can be marked 'override'

160 views
Skip to first unread message

David M

unread,
May 4, 2022, 10:19:10 AM5/4/22
to Chromium-dev
Dear All,
1) i have added 2 interface classes and one struct in mojom and built.
2) it created virtual functions to override
3) in new_tab_page.h and cc i wrote override functions and implemented.
getting an error of:
A)
../..\chrome/browser/ui/webui/new_tab_page/new_tab_page_ui.h(166,64): error: only virtual member functions can be marked 'override'
  void SetCredentials(new_tab_page::mojom::Credentials login ) override;


B) here "new_tab_page::mojom::Credentials" is struct and i used raw_ptr to set the  memeber variables using interface. did i missed anything??

C) when we need to use raw_Ptr , Unique_ptr? and how to instantiate?
thanks in advance
David

Reply all
Reply to author
Forward
0 new messages