MCPcopy Index your code
hub / github.com/python/cpython / add_flag

Method add_flag

Lib/mailbox.py:1642–1644  ·  view source on GitHub ↗

Set the given flag(s) without changing others.

(self, flag)

Source from the content-addressed store, hash-verified

1640 self._info = '2,' + ''.join(sorted(flags))
1641
1642 def add_flag(self, flag):
1643 """Set the given flag(s) without changing others."""
1644 self.set_flags(''.join(set(self.get_flags()) | set(flag)))
1645
1646 def remove_flag(self, flag):
1647 """Unset the given string flag(s) without changing others."""

Callers 2

test_flagsMethod · 0.95
test_info_and_flagsMethod · 0.95

Calls 4

set_flagsMethod · 0.95
get_flagsMethod · 0.95
setFunction · 0.85
joinMethod · 0.45

Tested by 2

test_flagsMethod · 0.76
test_info_and_flagsMethod · 0.76