xtd 0.2.0

This example simplifies this code by instantiating the xtd::action delegate instead of explicitly defining a new delegate and assigning a named method to it.

#include <xtd/xtd>
using namespace xtd;
using namespace xtd::forms;
using display_message = delegate<void(const ustring&)>;
void show_windows_message(const ustring& message) {
void write_line(const ustring& message) {
auto main()->int {
display_message message_target;
message_target = show_windows_message;
message_target = write_line;
message_target("Hello, World!");